initial setup automation
We've got HUNDREDS of databases. Dozens in active development.
Several obvious details are missing from the initial setup of a linked database. These are specific to VSS, but I'm sure apply to other SSC versions:
1) Remember the last used (VSS) Database path.
2) Remember the last Source Control Folder, BUT... SUGGEST the name of the new DB as the terminal project name.
3) Add a Check box to "Auto Commit" ALL objects.
The amount of retyping (or even copy/paste/edit) the same information over and over is quite annoying.
My use of Source Control is in its infancy, but it would appear that when you commit your changes to Source Control, an entry to your repository (for us its TFS) and the version number. From what I understand this is only used by the compare products. But why can't this link be used by Source Control to automatically link others to the same repository?
It would be good to have the ability to script DB linking and checkin.
You would specify the the TFS/SVN/Other path and the databases and be able to iterate over the whole instance and link all of the DB's. The ability to automatically commit these changes would be good also.
share database link configuration with other users or across machines rather than having to relink databases for each installation of SQL Source
I wanted to update this as some recent testing has shown we broke the workaround for this a while ago. We are however scoping out what it’d look like to solve this properly. We have many of your contact details, so will be reaching out to a few of you for help, but if you’re super keen to get involved feel free to post above or email me and we’ll get you involved.
If you are still looking for testers, I am interested.
Just checking in to see whether there's been progress here...having to re-link databases because I now have a new profile gah! To reiterate my point, if you aren't linked to source control yourself, the database still has an extended properties entry which states the location of the current check-in. A "we've identified a location, do you want to re-use it" type question would be most helpful.
Same problem. Hundreds of databases, multiple developers. We need the ability to copy the config out to all developers without error or duplication.
We continue to randomly get errors with database linkage issues. It would be nice if we could get a resolution to this soon as we have hundreds of databases that we have to re-link to source control.
Was this ever added? It was one of the big usability holes for us since everyone would have to manually add 100+ DB's themselves.
If you're shared, have SQL source control installed, I would want the DB to show as under source control in SSMS by default.
Brett Canter commented
I agree with the comment that a command line enhancement would be an excellent fix. We currently use SQL Compare to generate reports on changes but we automate this reporting using the sqlcompare executable. Something similar for source control would be invaluable
a command line option to setup linked dbs would be most effencient for our process
As a first step, if extended properties exist but MY copy of SSMS isn't linked, couldn't SourceControl just say "you're not set up, do you want to add this link"?
My entire team have had new machines built recently, we've had to re-connect every database :|
Honestly, I don't like the extended properties approach and would rather just see you guys create a Red Gate database that all team members could link up to.
3rd attempting to post this comment...
I've tried the steps below and the users get the linked databases, however they get a "grey" dot on them. When clicking on it they aren't prompted to get a local copy and say "yes", rather they receive an application error:
There is no working folder mapping for C:\Documents and Settings\sahar\Local Settings\Application Data\Red Gate\SQL Source Control 3\WorkingBases\y40aughq.j5u.
Which they continue to get each time they click elsewhere in SSMS
I tried this route and it appeared to work but the users got a "grey" dot on the green linked database. There was no prompt for them to say "yes" to, rather it generated a SQL Source Control application error:
"There is no working folder mapping for C:\Documents and Settings\<user>\Local Settings\Application Data\Red Gate\SQL Source Control 3\WorkingBases\y40aughq.j5u."
(which they continue to receive while working in SSMS)
The admin's last post was in April of 2012...It took me hours to set up and link all of the databases from 20 servers to SSC - I can't have 9 other developers doing the same thing. Surely there has to be a solid way of automatically having these developers linked to source control??? Not only do you need to give them the XML file, but you need to create one for each developer...to ensure they have the proper root path Ex: C:\Documents and Settings\doej\Local Settings\Application Data\Red Gate\SQL Source Control 3\Transients\xxx.ddz
I'm on the latest Beta...and from what I can tell there's no GUI options for SSC - does any one know if it's been added?
Unfortunately, Chris's solution was not workable for us. I believe this is still a need.
John Q Martin (@SQLServerMonkey) commented
I have the same request, we have a large development team and are going to be migrating to use SQL Source Control. We will be using the Shared development model and it would be really useful to not get the developers to link each database on the various servers.
Rather if they can just open management studio and then the Source Control plugin picks up which databases are under source control and sets up the plugin as required.
This issue still seems to exist for 2013. Any updates?
It seems to me there should be a configuration option available to the users to allow RedGate to store the configuration of databases to a specific "RedGateSourceSafeConfigurationDb" database. That way, we could manipulate that table easily to tell RedGate what the linkages are, and RedGate could write to the same table to store the information for new databases/developers.
@Chris, why won't the working folders come through, when I see them in the XML file?
AdminDavid Atkinson (Admin, Redgate) commented
The reason I ask is that we do have plans to add an auto-link for the shared case, although would you want it to auto-link for everyone, or just pre-populate the repo URL if a user chooses to link it? It's possible to also have something in the dedicated case so long as the extended property is set in the database, and this depends on how the dev DB has been restored/created.
Hi David, sorry didn't realise there was an update...I don't think it matters? What testing I've done, whether I've selected dedicated or shared it still has the same behaviour. I've considered your question...I can see why you wouldn't want it to auto-link if it's a dedicated database, but if it's shared I think it would be useful to either automatically link (or at least be given the option) to the exisiting repository...
AdminDavid Atkinson (Admin, Redgate) commented
@Justin - Are you on the shared database model or dedicated?