Please let me add the following question...
I tried the solution for and it's looking good, but as I try to insert the contents of the nodeBuffer into an XMLtype table, oracle db complains about the following "ORA-30937" and "ORA-06512".
The reason seem to be the missing namespace information.
xmlvar := XMLType(nodebuffer);
insert into C_AL2 values (xmlvar);
When I artificially edit my code and insert this information by hand, the code works.
nodebuffer := '<C xmlns="http://www.xxx.com/ABC" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance
Has anybody got an idea?