insert xml data into database table [message #251350] |
Fri, 13 July 2007 02:02 |
|
hi all,
please help me out from the following problem.
i am sending a xml file from where i want insert data into the database.If any body can post a example,it will be better for me to understand.Thank you in advance.
<?xml version="1.0" encoding="UTF-8" ?>
- <Return>
- <P1>
<ret_frm>2007-07-17</ret_frm>
<ret_to />
<VAT_RC_NO>223435.00000000</VAT_RC_NO>
<dealer_name>EREFSDF</dealer_name>
<dealer_address>DFGFDDFGD</dealer_address>
<pur_goods_amt>34534.00000000</pur_goods_amt>
<pur_goods_itc>2323.00000000</pur_goods_itc>
<pur_mrp_itc>2432.00000000</pur_mrp_itc>
<pur_mrp_amt>232.00000000</pur_mrp_amt>
<pur_goods_tax_1>343.00000000</pur_goods_tax_1>
<pur_goods_tax_4_itc>.0</pur_goods_tax_4_itc>
<pur_goods_tax_4>3455.00000000</pur_goods_tax_4>
<pur_goods_tax_12_itc>.0</pur_goods_tax_12_itc>
<pur_goods_tax_12>45.00000000</pur_goods_tax_12>
<pur_goods_rate_itc />
<pur_goods_rate>454.00000000</pur_goods_rate>
<pur_goods_comp_itc>.0</pur_goods_comp_itc>
<pur_goods_comp>454.00000000</pur_goods_comp>
<pur_goods_cap_itc>.0</pur_goods_cap_itc>
<pur_goods_cap>45656.00000000</pur_goods_cap>
<pur_goods_tot_itc>.0</pur_goods_tot_itc>
<pur_goods_tot>.0</pur_goods_tot>
<pur_raw_itc>.0</pur_raw_itc>
<pur_raw_amt>565.00000000</pur_raw_amt>
<pur_raw_tax_1_itc>.0</pur_raw_tax_1_itc>
<pur_raw_tax_1>565.00000000</pur_raw_tax_1>
<pur_raw_tax_4_itc>.0</pur_raw_tax_4_itc>
<pur_raw_tax_4>675.00000000</pur_raw_tax_4>
<pur_goods__12_itc>.0</pur_goods__12_itc>
<pur_raw_tax_12>56756.00000000</pur_raw_tax_12>
<pur_raw_tax_rate_itc>.0</pur_raw_tax_rate_itc>
<pur_raw_tax_rate>5675.00000000</pur_raw_tax_rate>
<pur_raw_itc>.0</pur_raw_itc>
<pur_raw_tot>56756.00000000</pur_raw_tot>
<int_rate>.0</int_rate>
<int_rate2>.0</int_rate2>
<int_rate3>.0</int_rate3>
</P1>
</Return>
|
|
|
Re: insert xml data into database table [message #251474 is a reply to message #251350] |
Fri, 13 July 2007 14:13 |
mchadder
Messages: 224 Registered: May 2005 Location: UK
|
Senior Member |
|
|
Hi there.
Well, there are literally a million and one ways that XML can end up in an Oracle database table, and loads of different ways of
storing the XML in that table.
You mention "i am sending a xml file", can you elaborate on this? You also neglect to mention the version of Oracle that you are using.
If you are on 9i or above, then you can utilise the XMLTYPE datatype in relational tables for storage of XML, but, as I said before, there are loads of different ways of storing the XML, each with advantages and disadvantages, and you need to bear in mind that whichever way you choose needs to be tailored to make it efficient to extract / query the data afterwards (if, indeed, you require to do so! ).
Elaborate a bit on your architecture, and we'll help further.
Regards
|
|
|