dbTalk Databases Forums  

How do you create an XML document using SQL

comp.databases.oracle comp.databases.oracle


Discuss How do you create an XML document using SQL in the comp.databases.oracle forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
DaveS
 
Posts: n/a

Default How do you create an XML document using SQL - 06-29-2004 , 03:14 PM






Hello,

I'm using Oracle 9.2 and would like to automatically save a copy of
each deleted record in XML format to another database table. There
would be one XML record for each deleted record. I'd like to store
the XML record in a CLOB. I've created a table and added a trigger to
capture the delete event but I'm not sure how to create the XML
document. Each deleted record is comprised of a single row from a
parent table and multiple rows from a child table. Heres the catch;
I don't want the solution to require me to specify each individual
column in each table. I'd like to use the wildcard(*) operator to
select the columns. The Oracle documentation I've read says to use
objects to create complex XML but you can't use the wildcard operator
to specify the columns. I've looked at using dbms_xmlgen which
supports the wildcard operator but I can't create a well formed XML
document. Any ideas or examples would be greatly appreciated.

Thanks

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.