Removing hidden characters from Clob

This is followup question to my previous question http://www.experts-exchange.com/Database/Oracle/Q_28668074.html#a40761213

I am comparing clob contents using  DBMS_CRYPTO.HASH and i'm running into problems where on the surface the clobs contents are the same, but there are hidden characters that are causing it not to show as the same. How can I remove any hidden characters so it will register as the same? I used regexp_replace to remove the white spaces, but looking at the HEX version it still shows as some trailing on the end, but I don't know what.

AdditionalSAVEsubmitted - How both look when returned

....A.d.d.i.t.i.o.n.a.l.S.A.V.E.s.u.b.m.i.t.t.e.d..... - Hex version of one

....A.d.d.i.t.i.o.n.a.l.S.A.V.E.s.u.b.m.i.t.t.e.d. - Hex version of the other
DBAnewbie77Asked:
Who is Participating?
 
slightwv (䄆 Netminder) Commented:
What is 'allowed'?

Check out the regex character classes:
http://www.regular-expressions.info/posixbrackets.html

drop table tab1 purge;
create table tab1(col1 clob);

insert into tab1 values('Hello');
insert into tab1 values('Hello' || chr(5));
commit;

select dbms_crypto.hash(regexp_replace(col1,'[^[:alnum:]]'),2) from tab1;

Open in new window

0
 
DBAnewbie77Author Commented:
Thanks for the link!  I tried using :ascii: and it wasnt supported, but the :alnum: worked.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.