SQLCI.exe and migration scripts

Automated deployment for web applications and databases

SQLCI.exe and migration scripts

Postby dbaumnnmdp » Fri Nov 15, 2013 9:22 pm

We are running SQLCI.exe for automating our SQL Server schema and static data changes as part of a TFS 2010 build. We are following the documentation found in this link: http://documentation.red-gate.com/displ ... n+Service#. We are deploying from source control directly to a downstream database with these additionalCompareArgs: /options:Default,IgnoreUsers,IgnorePermissions.

Basic schema changes and static data added via SQL Source Control come over just fine. However, if we require a migration script that doesn't appear to be run by the sqlci.exe.

Migration scripts run fine using the SQLCompare UI.

Thanks,

Dave
dbaumnnmdp
 
Posts: 2
Joined: Fri Nov 15, 2013 8:53 pm

Postby james.billings » Tue Nov 19, 2013 1:59 pm

Hi,

The SQL Compare Command Line requires different options to use migration scripts.

You'd need to have created two XML files, one for each of the extended properties we add to the database (storing the scripts location and the migration scripts location), then reference these using the /scriptsfolderxml and /migrationsfolderxml switches. In addition, you'd then use the /sourcecontrol1 and /revision switches.

See the full list of switches here (and please ignore if it says that the migrationsfolderxml is deprecated, it's still needed I think)
james.billings
 
Posts: 1120
Joined: Wed Jun 16, 2010 11:10 am
Location: Red Gate

Postby dbaumnnmdp » Fri Nov 22, 2013 10:50 pm

Hi James,

Thanks for your reply. However, we are not using SQL Compare directly but rather interfacing through the SQLCI.exe as indicated in the link. We are using MSBuild projects to construct the command line used to in conjunction with SQLCI.exe.

More information can be found here: https://www.red-gate.com/supportcenter/ ... d_in_sqlCI
dbaumnnmdp
 
Posts: 2
Joined: Fri Nov 15, 2013 8:53 pm

Postby DavidSimner » Mon Nov 25, 2013 10:41 am

We're currently in the process of re-writing the migrations functionality and sqlCI.exe will be updated towards the end of this re-write: http://www.red-gate.com/products/sql-de ... tions-beta

Until then, you can work around this problem by calling the SQL Compare command line directly as James suggested -- sqlCI uses the SQL Compare command line under the hood, and if you look at the output of sqlCI it should tell you precisely how it is calling SQL Compare command line. You'll need to adjust those command line arguments along the lines James said.
DavidSimner
 
Posts: 54
Joined: Thu Feb 04, 2010 6:05 pm


Return to Deployment Manager

Who is online

Users browsing this forum: No registered users and 1 guest