Insert xmlfile into a XMLType Column

Hi all,

what is the best / easiest way to insert (only, no update) a XML-file into a XMLType-column with the DOA 4.071 standard version ?
Thanks for any hint and code.

:-) thomas
 
You can execute an insert statement with a sys.xmltype.createxml() call. The parameter of this constructor can take a String (up to 4K), PL/SQL String (up to 32K), or temporary CLOB (unlimited size) as XML text. For example:

Code:
insert into my_xml_table
  (id, xml)
values
  (1, sys.xmltype.createxml(:xml_var))
The :xml_var must contain the contents of your XML document.
 
Back
Top