Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

why rtrim does not work?

User611482-OracleFeb 7 2008 — edited Feb 8 2008
I want to display only part of a column value in sql select. I use rtrim as following:

select rtrim(SESS_NAME, ' to ') src
from S_SESSION;

suppose the column value is 'A to B', I want to see

src
--------
A

but instead, I got the original string 'A to B'. why is that?
I tried replacing SESS_NAME with a dummy string, then rtrim works. However, I do need to parse from SESS_NAME.
Please help!
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 7 2008
Added on Feb 7 2008
8 comments
856 views