SQL Source Control works with

Team Foundation Server

Subversion

Git

Mercurial

Perforce

or any version control system with a command line

Key features of SQL Source Control

Automate SQL changes during deployments

Pre & Post deployment scripts can make SQL changes before and after your deployments. These scripts are managed within SQL Source Control to then be picked up when deploying with SQL Compare or SQL Change Automation.

How SQL Source Control helps with development and business processes

Deploy your database straight from version control

Avoid errors and stop those 4am deployments

Deploying database changes is nerve-wracking. You have to make certain that nothing breaks and you have to minimize downtime. When something does go wrong, you’re responsible and it can be hard to fix.

So for a lot of us, deployment means queuing up changes, coming in early (or staying late), and crossing our fingers that nothing goes wrong.

SQL Source Control gives you an alternative: deploy from a canonical version of your database in version control. You’re working with a stable version, which cuts the risk of deploying incomplete or incorrect changes.

Deploy straight from your repository

SQL Compare writes deployment scripts in minutes, making your release safe and efficient. You can deploy from SQL Compare or copy the script to review and run later. You can use SQL Compare to generate rollback scripts too.

With SQL Change Automation, you can set up an automated deployment process for your database, using your existing release tool, such as Octopus Deploy.

“I'm anxious to get SQL Source Control up and running as I know the only way to deliver high quality SQL code is by having it under a SCM tool, vigorously testing, (thank you for SQL Test) and being able to confidently and consistently build/deploy the code.

There is so much that Redgate is doing to make Agile Database Development a reality. I'll finally be able to tell my AppDev friends to stow it when they say that database development can't be agile.”

Paul Hunter, NightOwl Development

Track progress and pass any audit with a full change history

With SQL Source Control you can keep a full change history for your database and every object in it.

It shows you who made changes, when they made them, and why. You stay up to date with progress and you get complete oversight of the changes that go into production.

Pass any audit and prove regulatory compliance

A well-documented change management process is also essential to win the trust of auditors or investors.

With a complete record of development changes in SQL Source Control, you can pass audits and prove you comply with standards such as Sarbanes-Oxley or HIPAA.

“If we can prove we can track the entire history of our data’s lifecycle, we’ll pass any audit. If not, we face massive fines, legal charges, suspension from trading, and possible termination of the company. Faced with that, how could I afford not to source control my database? How could anyone?”

Lynton Mack, DBA, Cameco Corporation

Keep an eye on database changes and know who changed what and when

Without version control, it’s almost impossible to keep track of development. As teams are growing, it becomes more and more complex to check on progress and work out what work your team has completed. How did your database reach its current state? Who just broke the build – and how are you going to fix it?

With SQL Source Control you’ll know exactly who made changes, when they made them, and why. You stay up to date with progress and you get complete oversight of the changes that go into production.

“Yesterday a vendor made a change to our database which broke some customer extracts.

With SQL Source Control, I was able to find exactly what the problem was and fix it in minutes.”

How to solve some specific problems for database CI, such as keeping your data safe

How to set up the full process step by step

How SQL Source Control versions your database objects

Database version control is hard because there isn’t any source code. Instead, your queries change the state of the database.

SQL Source Control solves that problem by scripting each database object into a file in your version control system.

It’s possible to do this with an elaborate manual workaround, but SQL Source Control makes it easy for you in three ways:

You don’t need to leave SQL Server Management Studio – you can do it all with a few clicks in the Object Explorer.

You don’t need to remember to script out your files or instil that habit in new team members. SQL Source Control highlights your changes in the Object Explorer, so you see what’s sitting outside version control at a glance.

You don’t have to worry about referential integrity or data persistence. SQL Source Control sorts out the order of your changes and deals with keys and constraints for you. With migration scripts, you can specify how to deal with complex changes that affect your data, such as table splits.

When you’ve made your changes, you check them in with a couple of clicks, just like you would for your application code. SQL Source Control scripts out files that represent the new state of each object and saves them in your version control system.

Not only is it simple to share your work – you also have a history of every change to every object in your database, along with details of who made each change, when, and why.

“Before using SQL Source Control, we'd tried a whole bunch of things. Sometimes we passed around manual backups, or SQL CREATE scripts, but that meant only one developer could work on the database before we had to issue updates again. We tried Database projects in Visual Studio, but they were clunky, and rather fragile when we made substantial changes.

One of our developers eventually cooked-up his own sync tool. It was a time consuming project. We had to teach new developers how to use it, enforce certain conventions, and it only really worked when source and target could be accessed at once, which wasn't often.

SQL Source Control did everything that sync tool could do, without wasting time or causing frustration...Integration with SSMS and TFS saved us a lot of hassle, but the major benefit has been the time it’s saved us making and pushing database changes. I'm not sure I could give that up again.”