Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> convert binary of hex to NVARCHAR2 in 8i

convert binary of hex to NVARCHAR2 in 8i

From: patrick <patrick.chong_at_smartalsolutions.com>
Date: 17 Dec 2001 20:33:12 -0800
Message-ID: <7cbb3222.0112172033.73b45ea8@posting.google.com>


Does anyone know is there a sql conversion function which converts a string of hex into NVARCHAR2 in 8i?

Further, I have a table which has a column('regionc') defined in NVARCHAR2(40), when the function rawtohex applies to the column('regionc'), a set of hex value is returned. However, it does not seen to be a 2-byte hex representation. Also when I try to reverse the function using the hextoraw, it cannot displayed the original string as in NVARCHAR2.

select pkey, regionc, rawtohex('regionc'), TRANSLATE(hextoraw('726567696F6E63') USING NCHAR_CS) from table1

Please advise. Am I doing correctly?

Thanks
Patrick Received on Mon Dec 17 2001 - 22:33:12 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US