help.net


Musing on .Net

News

Windows Phone Apps I recommend

FotoBank


FotoIreland



hit counters






Open source CMS


My blog

Irish blogs

Locations of visitors to this page Get Chitika eMiniMalls

.Net useful

Blogs I read

PocketPC

SQL

Usability

Inserting Records Into SQL Server Using SqlBulkCopy

With the advent of .NET 2.0 Microsoft has incorporated SQL Server’s bcp command line utility into the framework. The System.Data.SqlClient.SqlBulkCopy class provides significant performance increases over regular inserts. It also works with the System.Data.SqlClient.SqlTransaction class.

Aside from offering DTS-like speed the SqlBulkCopy class is pretty flexible. SqlBulkCopy's WriteToServer method takes the following types as arguments:

  • DataRow[]
  • IDataReader
  • DataTable

Read more...

Comments

No Comments