Visual Studio 2013 SQL Schema Compare: Ignore Column Order

后端 未结 3 1166
北恋
北恋 2021-02-12 20:50

In Visual Studio 2013, is there a way to ignore column ordering when doing a Schema Compare? I see that this feature was removed from Visual Studio 2012 (according to this: htt

3条回答
  •  隐瞒了意图╮
    2021-02-12 20:55

    As described on this blog post, Ignore column order is now an option in SSDT version 17.0, which is compatible with Visual Studio 2015.

    If you’ve ever had to deal with accidental data motion when putting a column in the middle of a table definition, you’ll know how hard this can be to spot and manage. In this release you can now check the “Ignore Column Order” option in the Advanced Publish Options. This will append new columns to the end of an existing table rather than altering the table structure to add the column in its listed position.

    You can find the setting by going into the Advanced... button section of your publish profile, as well as in the Advanced... button section of the database project properties' Debug tab.

    You can also achieve the same effect by adding the following element to your publish.xml file:

    True
    

    Unfortunately I do not know of a way to have this work in Visual Studio 2013, but hopefully you have upgraded to a newer version of Visual Studio by now :)

提交回复
热议问题