No, I want to Insert all the XML data into SQL server 2005 database.
The XML and SQL server database 2005 as same schema
Main Topics
Browse All TopicsHi,
I have an XML file, including multiple tables and their records.
How can I insert the XML file into SQL server 2005 using VB.NET.
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
The data in XML file is like that
- <NewDataSet>
+ <HEALTH_ExaminationRec>
<ExaminationID>1</Examinat
<ProjID>23</ProjID>
<Date>2008-06-27T00:00:00+
<ExaminedBy>ghngg</Examine
<MedicalLisenceNo>ghgh</Me
<BArea>hgggf</BArea>
<SrNo>1</SrNo>
<EmpName>fghgfhg</EmpName>
<EmpNo>2222</EmpNo>
<Age>23</Age>
<Height>5'6''</Height>
<Weight>500</Weight>
<BodyTemp>37</BodyTemp>
<Pulse>23</Pulse>
<BloodPressure>180/200</Bl
<EyeTest>o.k</EyeTest>
<EarTest>ok</EarTest>
<ThroatTest>ok</ThroatTest
<UrineTest>o.k</UrineTest>
<X_RayTest>o.k</X_RayTest>
<Blood_Test>o.k</Blood_Tes
<Drug_Test>o.k</Drug_Test>
<Heart>o.k</Heart>
<Diabetes>o.k</Diabetes>
<Gastro_Entritus>o.k</Gast
<Asthma>o.k</Asthma>
<Posted>false</Posted>
</HEALTH_ExaminationRec>
+ <HEALTH_ExaminationRec>
<ExaminationID>1</Examinat
<ProjID>235</ProjID>
<Date>2008-06-07T00:00:00+
<ExaminedBy>Muhammad Kashif</ExaminedBy>
<MedicalLisenceNo>32156498
<BArea>Test</BArea>
<SrNo>1</SrNo>
<EmpName>ABC</EmpName>
<EmpNo>21</EmpNo>
<Age>30</Age>
<Height>5'5''</Height>
<Weight>50.5</Weight>
<BodyTemp>98</BodyTemp>
<Pulse>80</Pulse>
<BloodPressure>110 088</BloodPressure>
<EyeTest>NORMAL</EyeTest>
<EarTest>NORMAL</EarTest>
<ThroatTest>NORMAL</Throat
<UrineTest>NORMAL</UrineTe
<X_RayTest>NORMAL</X_RayTe
<Blood_Test>NORMAL</Blood_
<Drug_Test>NORMAL</Drug_Te
<Heart>NORMAL</Heart>
<Diabetes>NIL</Diabetes>
<Gastro_Entritus>NIL</Gast
<Asthma>NIL</Asthma>
<Posted>false</Posted>
</HEALTH_ExaminationRec>
+ <HEALTH_ExaminationRec>
<ExaminationID>1</Examinat
<ProjID>235</ProjID>
<Date>2008-06-07T00:00:00+
<ExaminedBy>Muhammad Kashif</ExaminedBy>
<MedicalLisenceNo>32156498
<BArea>Test</BArea>
<SrNo>2</SrNo>
<EmpName>XYZ</EmpName>
<EmpNo>23654</EmpNo>
<Age>35</Age>
<Height>5'6''</Height>
<Weight>75</Weight>
<BodyTemp>98</BodyTemp>
<Pulse>82</Pulse>
<BloodPressure>100 110</BloodPressure>
<EyeTest>NORMAL</EyeTest>
<EarTest>NORMAL</EarTest>
<ThroatTest>NORMAL</Throat
<UrineTest>NORMAL</UrineTe
<X_RayTest>NORMAL</X_RayTe
<Blood_Test>NORMAL</Blood_
<Drug_Test>NORMAL</Drug_Te
<Heart>NORMAL</Heart>
<Diabetes>NIL</Diabetes>
<Gastro_Entritus>NIL</Gast
<Asthma>NIL</Asthma>
<Posted>false</Posted>
</HEALTH_ExaminationRec>
+ <HEALTH_ExaminationRec>
<ExaminationID>1</Examinat
<ProjID>456</ProjID>
<Date>2008-07-04T00:00:00+
<ExaminedBy>Doc.</Examined
<MedicalLisenceNo>MLN 1234</MedicalLisenceNo>
<BArea>IPBA</BArea>
<SrNo>1</SrNo>
<EmpName />
<EmpNo />
<Age>0</Age>
<Height />
<Weight>0</Weight>
<BodyTemp>0</BodyTemp>
<Pulse>0</Pulse>
<BloodPressure />
<EyeTest />
<EarTest />
<ThroatTest />
<UrineTest />
<X_RayTest />
<Blood_Test />
<Drug_Test />
<Heart />
<Diabetes />
<Gastro_Entritus />
<Asthma />
<Posted>false</Posted>
</HEALTH_ExaminationRec>
+ <HEALTH_ExaminationRec>
<ExaminationID>1</Examinat
<ProjID>456</ProjID>
<Date>2008-07-04T00:00:00+
<ExaminedBy>Doc.</Examined
<MedicalLisenceNo>MLN 1234</MedicalLisenceNo>
<BArea>IPBA</BArea>
<SrNo>2</SrNo>
<EmpName />
<EmpNo />
<Age>0</Age>
<Height />
<Weight>0</Weight>
<BodyTemp>0</BodyTemp>
<Pulse>0</Pulse>
<BloodPressure />
<EyeTest />
<EarTest />
<ThroatTest />
<UrineTest />
<X_RayTest />
<Blood_Test />
<Drug_Test />
<Heart />
<Diabetes />
<Gastro_Entritus />
<Asthma />
<Posted>false</Posted>
</HEALTH_ExaminationRec>
+ <HEALTH_ExaminationRec>
<ExaminationID>1</Examinat
<ProjID>456</ProjID>
<Date>2008-07-04T00:00:00+
<ExaminedBy>Doc.</Examined
<MedicalLisenceNo>MLN 1234</MedicalLisenceNo>
<BArea>IPBA</BArea>
<SrNo>3</SrNo>
<EmpName />
<EmpNo />
<Age>0</Age>
<Height />
<Weight>0</Weight>
<BodyTemp>0</BodyTemp>
<Pulse>0</Pulse>
<BloodPressure />
<EyeTest />
<EarTest />
<ThroatTest />
<UrineTest />
<X_RayTest />
<Blood_Test />
<Drug_Test />
<Heart />
<Diabetes />
<Gastro_Entritus />
<Asthma />
<Posted>false</Posted>
</HEALTH_ExaminationRec>
+ <HEALTH_ExaminationRec>
<ExaminationID>1</Examinat
<ProjID>456</ProjID>
<Date>2008-07-04T00:00:00+
<ExaminedBy>Doc.</Examined
<MedicalLisenceNo>MLN 1234</MedicalLisenceNo>
<BArea>IPBA</BArea>
<SrNo>4</SrNo>
<EmpName />
<EmpNo />
<Age>0</Age>
<Height />
<Weight>0</Weight>
<BodyTemp>0</BodyTemp>
<Pulse>0</Pulse>
<BloodPressure />
<EyeTest />
<EarTest />
<ThroatTest />
<UrineTest />
<X_RayTest />
<Blood_Test />
<Drug_Test />
<Heart />
<Diabetes />
<Gastro_Entritus />
<Asthma />
<Posted>false</Posted>
</HEALTH_ExaminationRec>
+ <HEALTH_ExaminationRec>
<ExaminationID>1</Examinat
<ProjID>456</ProjID>
<Date>2008-07-04T00:00:00+
<ExaminedBy>Doc.</Examined
<MedicalLisenceNo>MLN 1234</MedicalLisenceNo>
<BArea>IPBA</BArea>
<SrNo>5</SrNo>
<EmpName />
<EmpNo />
<Age>0</Age>
<Height />
<Weight>0</Weight>
<BodyTemp>0</BodyTemp>
<Pulse>0</Pulse>
<BloodPressure />
<EyeTest />
<EarTest />
<ThroatTest />
<UrineTest />
<X_RayTest />
<Blood_Test />
<Drug_Test />
<Heart />
<Diabetes />
<Gastro_Entritus />
<Asthma />
<Posted>false</Posted>
</HEALTH_ExaminationRec>
+ <HEALTH_ExaminationRec>
<ExaminationID>1</Examinat
<ProjID>456</ProjID>
<Date>2008-07-04T00:00:00+
<ExaminedBy>Doc.</Examined
<MedicalLisenceNo>MLN 1234</MedicalLisenceNo>
<BArea>IPBA</BArea>
<SrNo>6</SrNo>
<EmpName />
<EmpNo />
<Age>0</Age>
<Height />
<Weight>0</Weight>
<BodyTemp>0</BodyTemp>
<Pulse>0</Pulse>
<BloodPressure />
<EyeTest />
<EarTest />
<ThroatTest />
<UrineTest />
<X_RayTest />
<Blood_Test />
<Drug_Test />
<Heart />
<Diabetes />
<Gastro_Entritus />
<Asthma />
<Posted>false</Posted>
</HEALTH_ExaminationRec>
- <HEALTH_ExaminationRec>
<ExaminationID>1</Examinat
<ProjID>456</ProjID>
<Date>2008-07-04T00:00:00+
<ExaminedBy>Doc.</Examined
<MedicalLisenceNo>MLN 1234</MedicalLisenceNo>
<BArea>IPBA</BArea>
<SrNo>7</SrNo>
<EmpName />
<EmpNo />
<Age>0</Age>
<Height />
<Weight>0</Weight>
<BodyTemp>0</BodyTemp>
<Pulse>0</Pulse>
<BloodPressure />
<EyeTest />
<EarTest />
<ThroatTest />
<UrineTest />
<X_RayTest />
<Blood_Test />
<Drug_Test />
<Heart />
<Diabetes />
<Gastro_Entritus />
<Asthma />
<Posted>false</Posted>
</HEALTH_ExaminationRec>
__________________________
There are many tables in XML file like HEALTH_ExaminationRec with their records
Business Accounts
Answer for Membership
by: jyparaskPosted on 2008-07-24 at 03:46:12ID: 22077651
do you want to insert the xml in a column or create the database from the xml file?