Oracle® OLAP DML Reference 10g Release 1 (10.1) Part Number B10339-02 |
|
|
View PDF |
The LTRIM function removes characters from the left of a text expression, with all the leftmost characters that appear in another text expression removed. The function begins scanning the base text expression from its first character and removes all characters that appear in the trim expression until reaching a character that is not in the trim expression and then returns the result.
To trailing characters, use RTRIM. To trim both leading or trailing characters, use TRIM.
Return Value
TEXT or NTEXT based on the data type of the first argument.
Syntax
LTRIM (text-exp [, trim-exp])
Arguments
A text expression that you want trimmed.
A text expression that is the characters to trim. The default value of trim-exp is a single blank.
Examples
The following example trims all of the left-most x's and y's from a string:
SHOW LTRIM('xyxxxyLast Word','xy') Last Word