Oracle® OLAP Expression Syntax Reference Release 11.2 Part Number E23381-01 |
|
|
PDF · Mobi · ePub |
TRIM
removes leading or trailing characters (or both) from a character string.
VARCHAR2
TRIM([ { { LEADING | TRAILING | BOTH }[ trim_character ] | trim_character } FROM ] trim_source )
LEADING
removes matching characters from the beginning of the string.
TRAILING
removes matching characters from the end of the string.
BOTH
removes matching characters from both the beginning and the end of the string. (Default)
trim_character
is a single character to be removed. By default, it is a space.
trim_source
is the text expression to be trimmed.
TRIM('0' FROM '00026501.6703000')
returns the value 26501.6703
.
TRIM(LEADING '!' FROM '!!Help! Help!!')
returns the value Help! Help!!
.