The %TRIM built-in function is used to trim/remove beginning and ending blanks from a field. Example
1 2 3 4 5 6 |
dcl-s locString1 char(50); dcl-s locString2 char(50); locString1 = 'I drive a Volvo'; // Gives 'I drive a Volvo ' locString2 = %trim(locString1); // locString2 will now contain 'I drive a Volvo' |