I want the comparison below to not show a difference. According to MSDN (see step 7), there should be a SQLCMD Variables function available which I cannot find. This documentation is for SQL 2010, but I am using 2012. There doesn't appear to be 2012 version of the documentation available on this page.

How can I specify the value of $(DatabaseName) so that this comparison will work? I already have the value specified in my database project settings.

SQL Schema Compare

有帮助吗?

解决方案

You can work around this by schema comparing your development database, rather than the project, to the live database. Keep in mind that you would have to deploy the project to your development database first.

FYI - The fact that the variables are not substituted is only a problem in the comparison window. The variables do not cause false differences during the comparison (in other words, Schema Compare does substitute the variables when comparing) and the variables are substituted when you update the target database.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top