I am trying to convert Unicode Character to rtf code. i.e. I have typed a unicode character م in wordpad and saved it. I opened the rtf file in notepad and it shows that it changed character م to \'e3 . Now I am trying to get this result via sql but failed to to so.
executing following queries answer in م
1) select chr('55685') from dual;
2) select utl_raw.cast_to_varchar2('D985') from dual;
but
executing following query does not result in م
SELECT UNISTR('\00e3') FROM DUAL;
Executing
SELECT CONVERT('م', 'US7ASCII') con FROM DUAL;
gives ?
Executing following code converts either into junk or into same characters.
begin
for con in (SELECT value FROM V$NLS_VALID_VALUES WHERE parameter = 'CHARACTERSET')
loop
htp.p(con.value || ': ' || CONVERT('م', con.value));
end loop;
end;
Does any built-in function to convert unicode to rtf in oracle actually exist?