Copy data between Microsoft SQL Server databases.
C#
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
lib untrack smo dlls due to licensing Jan 18, 2012
src - added ability to whitelist tables Oct 26, 2012
.gitignore Ignoring release directory Oct 27, 2012
LICENSE.md Add license Jan 30, 2014
README.markdown

README.markdown

SQL Server Bulk Copy console app

This is a C# console app that copies data between Microsoft SQL Server databases. Example use:

AppHarbor.SqlServerBulkCopy.exe --srcserver=db000.appharbor.net --srcusername=dbxx --srcpassword=srcpassword --srcdatabasename=dbxx --dstserver=.\SQLEXPRESSADV --dstusername=dbyy --dstpassword=dstpassword --dstdatabasename=dbyy --ignoretables=TableToIgnore --cleardstdatabase

For trusted connections, just skip both the username and password parameters.

Use option --checkidentityexists if you are getting sql exceptions ([table] does not contain an identity column.) when trying to clear tables without identity columns.

The SMO dlls cannot be distributed with the source code due to licensing restrictions. You need to get Microsoft SQL Server 2008 R2 Shared Management Objects from the Microsoft Download Center. Place Microsoft.SqlServer.ConnectionInfo.dll, Microsoft.SqlServer.Management.Sdk.Sfc.dll, Microsoft.SqlServer.Smo.dll and Microsoft.SqlServer.SqlEnum.dll in the lib\SqlServerManagementObjects directory.

If you have the SDK already installed, you can find all the necessary DLLs in the directory:

C:\Program Files (x86)\Microsoft SQL Server\100\SDK\Assemblies