RTrim( character_expression ) / LTrim( character_expression )
RTrim returns character_expression without trailing spaces.
LTrim returns character_expression without leading spaces.
Examples
select RTrim( ' abcde ' )
select LTrim( ' abcde ' )
Difference
On ASE, applying RTrim
or LTrim
on a string that only contains spaces yields the NULL
string. On MS SQL Server, applying RTrim
or LTrim
on a string with only spaces yields the empty string.