Override SSDT publish profile ConnectionString Override SSDT publish profile ConnectionString jenkins jenkins

Override SSDT publish profile ConnectionString


I had a quick look at the source code with reflector (Microsoft.Data.Tools.Schema.CommandLineTool.ValidationUtil) and what happens is that TargetConnectionString is read from the command line, then after that the value in the publish profile overwrites the value - that can't be changed I am afraid.

The interesting thing is that after it has the connection string from either /TargetConnectionString or the publish profile it then applies the individual properties such as /TargetDatabaseName so i think (untested but looks good from the code) if instead of passing /TargetConnectionString you pass the individual components such as:

/TargetUser, /TargetPassword, /TargetDatabaseName, /TargetServerName, etc.

Then I think it will override the connection string in the publish profile, it is quite hard to read so let me know how you get on!

ed