Batched Update in .NET 2.0

S

Sahil Malik

Would you say that in Yukon/.NET 2.0, it would be better to pass in the
entire dataset changes in all of the related parent-child tables - as a
dataset - into the Yukon CLR? That way you could have the cake and eat it
too viz, have a complex relation-ed dataset and yet be able to acheive the
update in one shot to the Yukon Sql Server.

Which brings up another question - why do people not use too much of that
approach by sending updategrams into Sql 2000 using SqlXml?

Of the above two approaches, which one would you recommend, and why?

- Sahil Malik
You can reach me thru my blog -
http://www.dotnetjunkies.com/weblog/sahilmalik
 
S

Sushil Chordia

Here are my 2 cents:
1. Updating Dataset using SQLCLR
a. If the Dataset(DS) is large (in order of MB) you dont want to send
the whole DS on wire.
b.You wan to use SqlServer Managed Provider to update the data if you
need more performance, else there are no real benefits.
c. Since Adapter logic is not current supported in the SqlServer MP, you
would have code your own adapter logic
d. How do you pass the DS as a paremeter to the UDF(User Defined
Functions) - by XmlSerialization (bad perf for huge DS), by
BinarySerialization(only with 2.0)

2. Batch Updates ( new in ADO.Net 2.0) - similar to updategrams
a. There is way to send batch updates to server in ADO.Net 2.0(using
SqlDataAdapter.UpdateBatchSize property)
b. Good for huge DS.
 

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