Retrieving XML into Oracle table -


itemprop = "text">

I work on a project where I have to write a stored procedure which retrieve data from an HTTP, XML service I am doing. The data should be returned in a table or cursor so that the client can read it. I have done some work which is already retrieving data from the service using ULL_HTPP. I do not know how to do that to convert that data into columns and rows from XML. I am searching the internet and looking for an example of an Oracle data table and returning to XML using XMLElement; But thanks in the other way!

There are several ways to do this

In a way a parser (probably Pearl Or Java in a differnt language) which is converted into XML in the insert statement

in PL / SQL it can see like this:

  your_xml: = XMLType ('& lt; Employment ID = "1" & gt; & lt; First & gt; Peter & lt; / Prev & gt; & lt; Previous & gt; Fox & lt; / previous & gt; & lt; ; / Employment & gt; '); EXPRACTVALUE (your_xml, '/ past') from Dual, inserting the job (empid, FIRST_NAME, LAST_NAME) into EXTRACTVALUE (your_xml, '/ @ id'), EXTRACTVALUE (your_xml, '/ first');  

I have been deprecated in the address EXTRACTVALUE Oracle 11.2, but I just want to describe the theory.

Another way is to save the entire XML document in a table (simple INSERT statement) where you created a column of data type XMLTYPE then you can see a view on this table , Which use the functions you've already searched for. It is also possible to update the XML document stored in the table instead of instead of TRIGGER .


Comments

Popular posts from this blog

winforms - C# Form - Property Change -

java - Messages from .properties file do not display UTF-8 characters -

javascript - amcharts makechart not working -