Home » SQL & PL/SQL » SQL & PL/SQL » Data migration from XML source to Oracle
Data migration from XML source to Oracle [message #188537] Sat, 19 August 2006 03:09 Go to next message
mymot
Messages: 225
Registered: July 2005
Senior Member
Hi,


Can i get some example to get idea about how data in xml form could be migrated to Oracle table?



Thanks
Re: Data migration from XML source to Oracle [message #188546 is a reply to message #188537] Sat, 19 August 2006 06:27 Go to previous messageGo to next message
a_developer
Messages: 194
Registered: January 2006
Senior Member
http://www.orafaq.com/faqxml.htm
Re: Data migration from XML source to Oracle [message #188547 is a reply to message #188546] Sat, 19 August 2006 06:28 Go to previous message
a_developer
Messages: 194
Registered: January 2006
Senior Member
here's a simple example from that URL:
create table XMLTable (doc_id number, xml_data XMLType);

	insert into XMLTable values (1,
	        XMLType('<FAQ-LIST>
	           <QUESTION>
	                <QUERY>Question 1</QUERY>
	                <RESPONSE>Answer goes here.</RESPONSE>
	           </QUESTION>
	        </FAQ-LIST>'));

	select extractValue(xml_data, '/FAQ-LIST/QUESTION/RESPONSE')  -- XPath expression
	from   XMLTable
	where  existsNode(xml_data, '/FAQ-LIST/QUESTION[QUERY="Question 1"]') = 1;

Previous Topic: Stored Procedure status- Oracle
Next Topic: Views
Goto Forum:
  


Current Time: Tue Dec 06 06:41:33 CST 2016

Total time taken to generate the page: 0.15062 seconds