I have next below xml value in CLOB column in Oracle 11g.
<Energy xmlns="http://euroconsumers.org/notifications/2009/01/notification">
<WEBSITE>WWW.VERLAAG.BE</WEBSITE>
<CUSTOMERID>xxxxxx</CUSTOMERID>
<Gender>M</Gender>
<Telephone>0000000000</Telephone>
</Energy>
I want to add a new node called: Language
to look like this:
<Energy xmlns="http://euroconsumers.org/notifications/2009/01/notification">
<WEBSITE>WWW.VERLAAG.BE</WEBSITE>
<CUSTOMERID>xxxxxx</CUSTOMERID>
<Gender>M</Gender>
<Telephone>0000000000</Telephone>
<Language></Language>
</Energy>
I've used next below sentence:
update tmp_tab_noemail_test_aankoop p1
set p1.sce_msg = insertchildxml(p1.sce_msg, '/Energy', 'Language',
xmltype('<Language><Language/>'),
'xmlns="http://euroconsumers.org/notifications/2009/01/notification')
.getclobval();
And also this one:
update tmp_tab_noemail_test_aankoop p1
set p1.sce_msg = APPENDCHILDXML(p1.sce_msg,
'/Energy',
XMLType('<Language><Language/>'),
'xmlns="http://euroconsumers.org/notifications/2009/01/notification')
.getclobval()
But any of these functions are working.
Any idea?