LTrim() returns the input string trimmed of any leading spaces.
Syntax:
LTrim(text)
Return data type: string
Example
Result
LTrim( ' abc' )
Returns 'abc'
LTrim( 'abc ' )
Returns 'abc '
Set verbatim=1;
T1:
Load *,
len(LtrimString) as LtrimStringLength;
Load *,
ltrim(String) as LtrimString;
Load *,
len(String) as StringLength;
Load * Inline [
String
' abc '
' def '];
Information noteThe "Set verbatim=1" statement is included in the example to ensure that the spaces are not automatically trimmed before the demonstration of the ltrim function. See Verbatim for more information.