Automatically link multiple databases in an instance or share config with team
nickfotopoulos
Posts: 13 Bronze 1
I'm in the process of migrating from one machine to another and its a huge PITA because of SQL Source Control. So far the only way i've found to move my config over is to copy the entire SQL Source Control 7 settings folder in AppData\Local over to my new machine. (500MB compressed, 2.5GB uncompressed)
Relinking the databases just isn't reasonable. I have 120+ databases across dozens of servers linked, and I haven't even linked all of our databases yet. Everytime we on board someone to the team they have to add each one as they go. This mostly works, but they inevitably forget to link a server and thus check in their changes quite a bit.
I wish SQL Source Control would allow you to share Linked Server config. Or could allow you to define a source control path format so you could link all databases on an instance.
Relinking the databases just isn't reasonable. I have 120+ databases across dozens of servers linked, and I haven't even linked all of our databases yet. Everytime we on board someone to the team they have to add each one as they go. This mostly works, but they inevitably forget to link a server and thus check in their changes quite a bit.
I wish SQL Source Control would allow you to share Linked Server config. Or could allow you to define a source control path format so you could link all databases on an instance.
Tagged:
Comments
https://github.com/EngageITServices/SOCAutoLinkDatabasesWorkingFolder
DevOps Mentor and Coach
Director of DLM Consultants
Creator of Speaking Mentors
Microsoft Data Platform MVP
Friend of Redgate
Twitter / LinkedIn
I wonder if this file copy method would work or be easier if the SQL Source were stored in git repos instead of TFS? I'll have to link a couple of databases to git repos and inspect the SQL Source Control AppData\Local settings to see if it is more self contained and copy friendly.
All of the RedGate tools could greatly benefit from some shared configuration settings for teams.
For TFS, check out this link instead:
https://github.com/MatthewFlatt/SOCAutoLinkDatabases
(The link I shared originally was updated to support Git. However, it was based on this earleir version which was designed to be used with TFS.)
That said *everything* is much easier once you move to Git. ;-p
DevOps Mentor and Coach
Director of DLM Consultants
Creator of Speaking Mentors
Microsoft Data Platform MVP
Friend of Redgate
Twitter / LinkedIn