SQLBulkCopy like for update?

  • Thread starter Thread starter Francis
  • Start date Start date
F

Francis

Hi all

Is there something similar to SQLBulkCopy but instead of inserting new
records, to update existing based on say, the primary key? We have to
update a large table and executing thousands of update queries takes
forever.

Thanks in advance!
 
Sure. This is called synchronization. While there are a number of ways to do
this, one of the easiest is to use the new ADO.NET 3.5 Sync Services
classes. With Synchronization, the traffic being handled up and down the
wire is handled by sync services so you never have to execute a SELECT or
any DML queries like UPDATE. You work with a locally cached (in memory or on
disk) subset of the database.

--
__________________________________________________________________________
William R. Vaughn
President and Founder Beta V Corporation
Author, Mentor, Dad, Grandpa
Microsoft MVP
(425) 556-9205 (Pacific time)
Hitchhiker's Guide to Visual Studio and SQL Server (7th Edition)
____________________________________________________________________________________________
 
Back
Top