history rename
Treat object RENAME as Source Control (TFS) file RENAME not Drop & Add which deletes Source Control history of the object/file
More details can be found here: https://redgatesupport.zendesk.com/hc/en-us/requests/88809
-
Dani Avni commented
another option is to have in SQL Source Control the ability to auto create migration scripts for specific scenarios. so i would map the renamed elements (like in sql compare) and have the change script generated automatically
-
Dani Avni commented
using SQL Source Control 3 and SQL Compare 10.2
i renamed a table from X to Y. as others noted, SQL source control sees the change as drop X and create Y. i want to create a migration script but that would take too long as the script has to drop relations with other tables, related SPROCS and that would take too long to write and debug.on the other side, SQL Compare 10.2 knows how to handle a rename of a table. all i have to do is map the tables and i get the table renamed with a few clicks.
my suggestion: allow on commit on sql source control to add rename hints that sql compare can use. for example on the commit i will define a migration script as a rename of X to Y. that in turn will cause SQL compare to see this hint and automatically set up a rename of table X to Y