Trim Spaces in a Select [message #8181] |
Fri, 01 August 2003 15:47 |
Ted
Messages: 9 Registered: June 2002
|
Junior Member |
|
|
Hi,
I have values in a column that I need to trim spaces from.
There is a table with a cloumn called "type" some values in this column are "New Buy", "Old Action Request" etc.
What I need to do is select those vlaues out but have them displayed in the folowing format:
NewBuy
OldActionRequest
No spaces between the words. Is there an SQL funtion that will eliminate the space?
|
|
|
Re: Trim Spaces in a Select [message #8182 is a reply to message #8181] |
Fri, 01 August 2003 15:52 |
Todd Barry
Messages: 4819 Registered: August 2001
|
Senior Member |
|
|
The third parameter to the function (not specified above since we are just removing, not replacing) indicates what character(s) should substitute.
sql>select replace('Old Action Request', ' ') from dual;
REPLACE('OLDACTI
----------------
OldActionRequest
|
|
|