My database (10gR2) is single-byte (NLS_CHARACTERSET = WE8DEC).
I have a Unicode XML file that I would like to parse. If I read the file into a CLOB and try to convert it to an XMLType, Oracle chokes when the XML contains special characters (in this case Norwegian characters such as "øæå").
ORA-31011: XML parsing failed
ORA-19202: Error occurred in XML processing
LPX-00216: invalid character 184 (0xB8)
If I read the file into a NCLOB, then explicitly convert this to a CLOB using TO_CLOB, the XMLType constructor succeeds. However, this conversion produces "ugly" results. For example,
bølle gjær
becomes
bÿlle gjÿr
Is there any way I can perform the conversion from NCLOB with Unicode to single-byte CLOB and still keep the special characters intact? (I am especially interested in proper conversion of just the three Norwegian characters "øæå", other special symbols and characters are not that important in this case.)