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!

LTRIM function with = Operator

vis1985May 10 2016 — edited May 10 2016

Hi,

I am using LTRIM function with = operator. For some LTRIM its giving correct resultIt's giving me some different results like below.

select LTRIM('GRAIN=HASH','GRAIN=')  AS RES from dual; 

RES

----

HASH

but for below I am getting some different results.

select LTRIM('GRAIN=NONE','GRAIN=') as RES from dual;

RES

---

ONE

select LTRIM('GRAIN=NANE','GRAIN=') as RES from dual;

R

-

E

select LTRIM('GRAIN=RAHUL','GRAIN=') as RES from dual;

RES

---

HUL

Please let me know why LTRIM behaves like this.Thanks

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 7 2016
Added on May 10 2016
3 comments
210 views