query against XML dataset possible ?

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

Guest

I have an XML file that is strongly typed with a schema & read in to a dataset
Now I thing I would like to 'select on certain criteria' - to create a subset to show in a different grid

Is it possible to do that ? I have yet to find an example.
Or do I have to work with XPath to get a subset

Thanks Andrew
 
Specifically I would like to have an expression like
transactionrecord = dataset.tables["transactionrecord"]

I did find a DataTable.Selec
another method about Compute - which takes some string expression

" Select UNIQUE * from transactionrecord where fieldname_1= 'ERROR'

Is this possible ?? Seems like it might be...
But I dont know what might be supported. In my case I have a windows service running on a serve
and I want to look at the unique errors found during the process. ( The data is logged to a monthly file )

Thanks
 
You can use some of the Find, Filter and Select methods available
in the DataSet, DataTable and DataView classes. check the docs for examples.
Peter
andrewcw said:
I have an XML file that is strongly typed with a schema & read in to a dataset.
Now I thing I would like to 'select on certain criteria' - to create a
subset to show in a different grid.
 
Hi andrewcw,

Thanks for your feedback.

Yes, to do the "DISTINCT" function, you have to determine it through loop
yourself.

If you need further help, please feel free to post.

Best regards,
Jeffrey Tan
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top