## Syntax ```mermaid %%{init: { 'theme': 'base', 'flowchart': { 'padding': '7', 'nodeSpacing': '20', 'rankSpacing': '20' }, 'themeVariables': { 'fontSize': '11px', 'fontFamily': 'Arial' } }}%% flowchart LR Start((START)) --> | | RIGHT[RIGHT]:::quoted RIGHT --> End((END)) ``` ## Purpose The `RIGHT` SQL function extracts a substring from a value with the given length from the right side. Keyword is also used with joins. Parameters: - Input: Text to extract substring from. - Length: Maximum length of the substring. Returns: Substring from the right side of the input.