Skip to main content
RIGHT_SUBSTR

Extracts the rightmost characters of a text string up to a specified length

Updated over a week ago

Description

The RIGHT_SUBSTR() function is used to extract a specified number of rightmost characters from the end of a text string. It's useful for tasks like truncating text or extracting suffixes from text.

Syntax

RIGHT_SUBSTR(text, number)

Output

text

Variables

  1. text: The input text string from which you want to extract characters.

  2. number: The number (length) of characters to extract from the right side of the text.

Example

RIGHT_SUBSTR(`Original Text`, 5)

ID

Original Text

RIGHT_SUBSTR

1

Hello, World!

orld!

2

Example Text

Text

3

Savant Analytics

ytics

Did this answer your question?