DataSets are very "cure all" objects. They allow binding (for one thing) in
a winforms application, and thus have some overhead as far as implementing
the IEditableObject interface.
So you're saying "why is he telling me about a winforms app? I'm in the
asp.net newsgroup".
Because you pay that price for using a DataSet (or strongly typed dataset).
Even in an asp.net application.
You can do a google search for
IDataReader DataSet
and you'll find some references about that.
You have to ask yourself a few question. Do I need the entire collections
of objects in memory for anything?
Am I just binding data to some output (repeater, gridview, etc)?
Here is one option for reducing overhead.
http://sholliday.spaces.live.com/Blog/cns!A68482B9628A842A!140.entry
Use an IDataReader to put your data_values into objects, and then those
objects into collections.
You can also (usually) bind a repeater control (one example that is) to an
IDataReader, although personally I don't like having IDataReaders floating
around in the presentation layer.
It this a "quickie application"? Or something that's going to be around for
a while.
Keep in mind, that Rapid Development doesn't always mean (or perhaps seldom
means) ... "good development".
"Aleks Kleyn" <Al********@discussions.microsoft.comwrote in message
news:92**********************************@microsof t.com...
>I use in my asp.net code dataset and populate datatable using dataadapter.
The problem is that my code demand huge amount of memory and I am looking
for way reduce this demand.
At this time I keep links to dataset, dataadapter and datatable in
session.
As I understand datatable is class and specific datatable does not belong
directly to dataset and using the same dataadapter I can populate two
datatables different way from the same real table. Does it mean that if I
move dataset to application level and limit scope of dataadapter and
datatable to specific page I will save in memory. Or better to keep
dataset
on level of session collection?