I'm working on a version 11.2 database with
NLS_CHARACTERSET = WE8MSWIN1252
and
NLS_NCHAR_CHARACTERSET = AL16UTF16
I've got some UFT8 characters being sent to the database as raw data. I need to be able to store this in a readable format and I think the only option is an NVarchar2 column.
I think the solution should include something like this:
utl_raw.cast_to_nvarchar2(
utl_raw.convert(
r => <raw data>,
to_charset => 'AL16UTF16',
from_charset => 'UTF8'))
but that gives me an exception: ORA-06502: PL/SQL: numeric or value error
Also, am I right in thinking that any Varchar2 column in this database can only hold single-byte characters (from WE8MSWIN1252) even if the size is defined as "
n char"?
I've not worked much with different character sets so any help would be appreciated. Thanks.