SQL Queries on XML Files

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hallo

I have an XML data file and I would like to run an SQL query over this file. How should I do this

Nigel...
 
Hi

If I understood your query correctly....

First you load xml file data into temporary tables.
Then using the above data formulate SQL Query and run it against the database.


Hope this gives any idea to you.
Ravikanth[MVP]
 
Thanks for the reply

I would prefer not to import the file into a database. Do you know if there is a way to do do this directly in the dataset

ds.readxml(PathToXML
and then?...

Nigel...
 
Hallo Bin Son

Thanks for the reply, this is very helpfull

I was trying to use datasets as a database where I could have several interlinked tables. Then it is quite handy to use SQL tocreate queries across these tables. Unfortunately my target platform (Smartphone) does not have any databases (SQLCE is not supported) and therfore I must use XML functionality

Dataset suport multiple tables with foriegn keys, is there really no way to query these with SQL

Thanks again..

Nigel...
 
Hi, Nigel

SQL has to be run against a SQL database. You can only filter and sort on a dataset
Instead you can use XPath or XSLT to find data.
And there will be a more powerful XQuery language that will be the SQL equivalent for XML, however, it is still in process

Bin Song, MCP
 
Back
Top