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!

hexadecimal to ascii convert function - I need null result for others

3175725Feb 12 2016 — edited Feb 24 2016

hi,

I have a coloumn whihc is vachar2 and it has numbers and hexadecimal ascii codes both. I need to convert ascii codes to strings, but keep numbers.

I can convert hex to ascii like below

select utl_raw.cast_to_varchar2(hextoraw('4B414C414E42494C4749')) from dual;

select utl_raw.cast_to_varchar2(hextoraw(EXCHANGE_ID)) from mytable ;

results;

--------

Capture.JPG

Result has lots of garbage characters due to numbers which coloumn have. I only need meaningful values like "Kalanbilgi" or "Arayanibil".

This post has been answered by Chris Hunt on Feb 16 2016
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 23 2016
Added on Feb 12 2016
26 comments
13,486 views