XML Database (MOSC)

MOSC Banner

XMLTYPE constructor, XML encoding and DB characterset

edited Jul 29, 2013 5:28AM in XML Database (MOSC) 4 commentsAnswered
Hello all,

I just wondering about the characterset in the XML encoding value when calling the XMTYPE constuctor

There are 2 Databases Oracle 11.2.0.3, one with AL32UTF8 characterset and one with WE8ISO8859P1 characterset

For every test the same XMLTYPE constructor call is used:
select xmltype('<?xml version="1.0" encoding="UTF-8"?><name>xy</name>') from dual;



First considering the AL32UTF8 DB:


export NLS_LANG=AMERICAN_GERMANY.AL32UTF8
sqlplus ...
SQL> select xmltype('<?xml version="1.0" encoding="UTF-8"?><name>xy</name>') from dual;

XMLTYPE('<?XMLVERSION="1.0"ENCODING="UTF-8"?><NAME>XY</NAME>')
----------------------------------------------------------------------------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-8"?><name>xy</name>

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center