>> "System.Data classes is that you have to write tedious  <http://ado.net/>
ADO.NET code to do all the CRUD"

What about the data adapter.Update command - it does it all for you.

 

Well, sort of. I remember writing database code back in the Framework 1.x
days where I'd use the DbCommandBuilder to complete the adapter before doing
updates and deletes. It seemed weird the way it used the Select command to
get the schema information for the Update. For some reason I never ran with
this technique and got into the habit of using AddParameter with SQL
strings, perhaps because I felt I had more control. I also remember that the
builder generated commands are long and full of AND and OR conditions, which
also irritated me by being so restrictive.

 

In hindsight, I guess you're right that less code is required if you use the
builder and feed the DataSet directly into the Update method. Next time I'm
writing some raw ADO.NET code (if ever) I'll give it a bash for old times
sake and see how it goes.

 

As much as I admire the clarity of the DataSet, DataTable and DataRow
classes, I do get sick of the row.IsFooNull() calls all the time to deal
with nullable columns.

 

Cheers,

Greg

Reply via email to