Trim space from a string : TRIM « Char Functions « Oracle PL / SQL






Trim space from a string

 
SQL>
SQL>  select '"' || trim( ' ' from '   This is a string    ' ) || '"' "Result"
  2      from dual
  3    /
Result
------------------
"This is a string"

1 row selected.

SQL> --

 








Related examples in the same category

1.Simple demo for TRIM function: removes all specified characters either from the beginning or the ending of a string
2.TRAILING: trim from the end of a string
3.LEADING: trim from the beginning of a string
4.TRIM(TRAILING 'A' FROM 'ABCA') trail
5.TRIM: removes leading and trailing characters from a string
6.TRIM from both sides
7.Characters rather than spaces are trimmed
8.Nesting TRIM function
9.TRIM Leading and Trailing Zeroes
10.Trim trailing space from a string