Return to String Function Index
String Function Syntax and Examples
RIGHT( )The RIGHT() function returns a specified number of characters from the right side of a string.
Syntax:
RIGHT(string,length)
where:
length specifies the number of characters to return. If a negative integer is specified, all rows will be rejected. If length is greater than the length of string, the entire string is returned.
Example:input: samplestring
IMPORT @sample.dat
{RECORD
{
field1 *\r\n
}
schema1.table1
{
col1 RIGHT(field1,4)
col2 RIGHT(field1,6)
col3 RIGHT(field1,30)
}}
Results:
schema1.table1.col1 ring schema1.table1.col2 string schema1.table1.col3 samplestring
Return to String Function Index