Bob Dylan
Bob Dylan

Reputation: 4453

How to convert XML file to a Database?

I recently downloaded the SO Data Dump and was wondering how I could convert it from XML to a DB that I could use in my .NET applications.

Upvotes: 2

Views: 9099

Answers (5)

Kirtan
Kirtan

Reputation: 21695

Here's a wiki article describing the process of converting the XML data dump to a database by using stored procedures.

SQLServerPedia site contains many other articles related to SO -

Upvotes: 5

Jon Galloway
Jon Galloway

Reputation: 53125

You could try XML Bulk Load.

Upvotes: 3

daniel
daniel

Reputation: 9835

Hm, just use a XML parser, and make the database schema as you wish...you can also map the xml to a database directly... http://en.wikipedia.org/wiki/XML_database Do some more reading...really..

Upvotes: 1

Arsen Mkrtchyan
Arsen Mkrtchyan

Reputation: 50732

you can convert it to DataSet using DataSet.ReadXml Method and that insert datatables to database

Upvotes: 2

Foredecker
Foredecker

Reputation: 7493

C# handles XML natively very well. Unless there is a large amount of XML, simply use LINQ to XML.

If you have large amounts of XML, then handling it in streaming mode is proably less work than putting it in a DB

Upvotes: 1

Related Questions