31 Oct 2012 Update 2: Microsoft made Team Foundation Service (formerly TFSPreview) public today! – Andy
31 Oct 2012 Update 1: SQL Source Control 3.1 is available! – Andy
12 Oct 2012 Update: The SQL Source Control 3.1 update is currently unavailable. I will provide additional updates when this version is re-released. – Andy
I am excited that RedGate’s SQL Source Control now supports connectivity to TFSPreview Team Foundation Service, Microsoft’s cloud-based Application Life Cycle Management portal. Buck Woody (Blog | @buckwoody) and I have written about TFSPreview (the test version of Team Foundation Service) at SQLBlog already:
- Team Foundation Server (TFS) in the Cloud – My Experience So Far (Buck)
- Introducing TFSPreview: Application Lifecycle Management in the Cloud!
- Using TFSPreview: Step 1, Connecting
Microsoft’s commitment to cloudtech is strong and producing very cool features, in my humble opinion. It’s neat to see third-party vendors like RedGate providing connectivity to these features.
Prerequisites
SQL Source Control’s support for Team Foundation Service is new and there are software prerequisites at the time of this writing (Oct 2012):
- SQL Server 2012 Management Studio (SSMS 2012)
- Team Explorer for Visual Studio 2012 – The Team Foundation Service 2012 client.
You must have these tools installed to use SQL Source Control 3.1 with Team Foundation Service.
Setup Your Free Trial
Navigate to the SQL Source Control download page:
Download and install SQL Source Control 3.0.
Once SQL Source Control 3.0 is installed, open SSMS 2012. Your environment should display the SQL Source Control page shown in Figure 2:
Click the Help dropdown and click “Check for Updates…”:
At the time of this writing, you will find an available update from SQL Source Control 3.0 to version 3.1 as shown in Figure 4:
Download the new version. You will need to shut down SSMS to install the update as shown in Figure 5:
Once the update is installed, re-open SSMS 2012. Connect to an instance and select a database:
Click the link labeled “Link database to source control”. When the Link to Source Control window displays, select the Team Foundation Server (TFS) Source Control System option. If you do not have the Team Explorer for Visual Studio 2012 client installed, you will receive the error displayed in Figure 7:
If the Team Explorer for Visual Studio 2012 client is installed you will be presented with a screen similar to that shown in Figure 8:
But you cannot yet use SQL Source Control with Team Foundation Service. First, click the link beneath the Server URL textbox that states “To link to TFS2012 or tfs.visualstudio.com, you must edit a config file. Learn more”
Follow the link to the support page and then follow the instructions on the page. Open the RedGate_SQLSourceControl_Engine_EngineOptions.xml file as shown in Figure 10:
Edit the file according to the instructions on the support page:
When complete (at the time of this writing), the file will appear similar to that shown in Figure 12:
I set up SQL Source Control on a new Windows Server 2012 virtual machine, so there were a lot of default permissions in place. When attempting to connect with Team Foundation Service, I had to add several (~8) URLs to Trusted Sites. Even after that, I saw the Windows Live login screen appear briefly before being replaced by the message window in Figure 13:
I closed this window and attempted to connect to Team Foundation Service once more and was successful, reaching the screen shown in Figure 14:
After reaching my Team Foundation Service site, I clicked the Browse button to select a database folder as shown in Figure 15:
I selected a Team Project (Demos) from my default collection of TFS Team Projects and created a folder named CloudDemo:
Once the folder was created I could select it as shown in Figure 17:
Returning to the Link to Source Control window, I see my selected Database folder:
Click the Link button to start the Source Control Link process. A message balloon informs me the link is complete, as shown in Figure 19:
The First Commit
I see a visual indication the database is under SQL Source Control in the SSMS 2012 Object Explorer:
Objects added to the database – like the RainDrops table shown in Figure 21 – are marked visually for Commit:
The Commit Changes tab of the SQL Source Control window provides a space to enter version comments before performing the Commit operation as shown in Figure 22:
When the Commit operation completes, SQL Source Control provides excellent feedback:
Awesome!
Conclusion
Source-controlling code of any kind is important. Having the ability to store source code remotely is handy for many Application Life Cycle Management scenarios. tfs.visualstudio.com is constantly adding features to support developers practicing continuous (or continual) integration methodologies.
I like the manner in which SQL Source Control approaches database source control. I especially like that when I log into the Source page of my project at Team Foundation Service, I see something that looks similar to Object Explorer:
I admire the thought RedGate put into the design of SQL Source Control and believe the product is well-positioned to support database development now and – with the addition of tfs.visualstudio.com support – for the foreseeable future.
:{>
Hi, any idea when you will re-release 3.1?
Hi Rake0,
SQL Source Control 3.1 has been re-released!
:{>
No Spaces. This was a big help.http://www.red-gate.com/messageboard/viewtopic.php?t=15959&highlight=team+service
Just to say that the whitespace thing seems to be really critical. I initially had mine split over lines as in the example, but I got the screen saying I needed to install the team explorer client. Moved everything to a single line and it worked
Have you ay idea what the URL’s were that you had to add. I can’t seem to get my connection working. Its telling me that Team Foundation Services are not available at the URL I have specified. I’m wondering if its a security issue as I’m running WIndows 2008 on my laptop
OK. It turned out my issue was some old TFSPreview instructions that told me to add port 8080 to the URL. Once I took this out it just worked
Doh!