please help

B

boxim

I'm having a mid-project dilema about using DataSets vs customised classes
for managing records

I know that DataSets can have constraints applied to maintain referential
integregrity with other tables held in the dataset (memory)
However, we wanted a set of data manegement classes that provided actual
properties to the members of the object's data, e.g. Company.Name to be the
company name, not ds.Tables["company"].Rows[0]["comp_name"].
Ok, so I could make a typed classe derived from DataSet that provides the
data as properties from the underlying
DataSet.Tables["table"].Rows[0]["field"]
But it isn't a dataset, it's a single record, is it a DataRow?
So I could derive a class from DataRow that could form the basis of my
entity, then derive a new class from DataSet that adds "entities" instead of
DataRows - or am I recreating the wheel?

In my "entity" class, I need to perform optimistic concurrency checking on
update and deletes, this though is already handled by DataSet.
I'll need a Save or Update function too, and to know whether the entit's
data has been change, i.e. is it IsDirty?... oh my god. this sounds like a
dataset.

If anyone's written an enterprise application using web services, a database
and strongly typed datasets or custom classes please could you post a brief
explanation of how you did it so I can get an idea of the most common and
hopefully best way managing data within and windows application

TIA

Sam martin
 

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

Top