Dataset question.

  • Thread starter Thread starter john
  • Start date Start date
J

john

I am trying to provide the capability to search an xml
document based on different options. I am reading the xml
document into a dataset and I would like to loop through
the dataset deleting records that don't meet the
criteria. Is there another way to do this? an example is
below for more clarity

I have an xml document with the following elements: Id,
Price, Description, Status

My xml document has many more elements and I would like to
allow them to search on any and/or all of the elements. I
am a bit new to data morphing in .net, so ANY help you
could give would be great. Thank you very much for your
help!
 
Hi John,

First of all there is mostly nothign wrong with looping through a dataset.
Do not forget whatever routine you use under the cover it should be finded
and there would be some looping.

However there are a lot of methods, some of them
The datarowcollection find (needs a primary key)
The datatable.select
The dataview.rowfilter (the most performance without primary key)

If you have more question feel free to ask.

I hope this helps?

Cor
 
John,
In addition to the methods Cor identified.

David Sceppa's book "Microsoft ADO.NET - Core Reference" by MS Press is an
excellent tutorial on ADO.NET plus a good desk reference on ADO.NET once you
learn it.

It covers both the how & why of using the various methods Cor identified.

Hope this helps
Jay
 
Thanks for the tip, and for the book reference. I've been
looking for a good ado reference book.
 
Back
Top