Hello,
I am working on the problem which involves using DOM to parse XML file and then using
JDBC store the relevant data in the Oracle database. First part of the problem is done - parsing the file. For the second part I am very confused as to how to go about it as XML is a hierarchical data and Oracle is a relational data. How can I do this mapping.
For example, my XML file looks like this
<my_info>
<name>
<first_name>...</first_name>
<last_name>...</last_name>
</name>
<age>... </age>
<address>...</address>
</my_info>
What I want to do is to create a table with the name - my_info and then create columns like first_name, last_name, age, address. But how do I handle the issue that the column name should be first_name and last_name and not name. In some other case I might need to have the column name to be name and not first_name and last_name. Is there somegeneral way to work on such type of problems.
Please help.
Thanks
Vibha.