SQL Source Control is a powerful tool that integrates with SQL Server Management Studio (SSMS) to provide version control for your database schema objects. In this article, we will explore some common questions and concepts related to SQL Source Control.
What is SQL Source Control?
SQL Source Control is an add-in for SSMS that allows you to link your database to a source control system, such as Subversion (SVN) or Team Foundation Server (TFS). It provides a seamless integration between SSMS and the source control system, allowing you to track changes to your database schema objects and easily collaborate with other developers.
How does SQL Source Control work?
When you link your database to a source control system using SQL Source Control, it creates an XML file on your client machine that stores the association between the database and the source control repository. This XML file is used to track changes and synchronize your database with the repository.
SQL Source Control polls your database server to detect if any changes have been made to the database. It then displays blue indicators on the Object Explorer in SSMS to show which objects have been modified. You can easily commit, get, or undo changes using the SQL Source Control interface in SSMS.
Benefits of using SQL Source Control
SQL Source Control offers several benefits for database developers:
- Version control: You can track changes to your database schema objects and easily revert to previous versions if needed.
- Collaboration: Multiple developers can work on the same database and easily share their changes using the source control system.
- History tracking: You can view the history of changes made to each object, including who made the change and when.
- Deployment: SQL Source Control integrates with Red Gate’s SQL Compare tool to deploy changes to different environments, such as development, testing, and production.
Common Questions about SQL Source Control
Here are answers to some common questions about SQL Source Control:
- Is there support for Sourcegear Vault? SQL Source Control currently supports Subversion (SVN) and Team Foundation Server (TFS). Support for other source control systems may be considered based on user feedback.
- Is source control installed on each desktop that runs Management Studio? Yes, SQL Source Control needs to be installed on each client machine that runs SSMS in order to access the source control features. However, the actual source control system is a server-level item that should be centralized.
- What is the impact of SQL Source Control on SSMS? The performance of SQL Source Control depends on the size of your database and the number of database developers. It polls your database server to detect changes, but this can be configured to optimize performance.
- Does SQL Source Control handle CLR objects? Yes, SQL Source Control supports CLR objects. Any issues related to 64-bit CLR objects have been fixed in the latest version.
- What happens if someone alters an object that doesn’t have SQL Source Control? If someone does not have SQL Source Control, they will not be notified of changes and will not be able to commit those changes to source control.
These are just a few examples of the questions that are commonly asked about SQL Source Control. The tool offers many more features and capabilities that can greatly enhance your database development workflow.
Conclusion
SQL Source Control is a valuable tool for database developers that allows for easy version control and collaboration. By integrating with SSMS and a source control system, it provides a seamless experience for tracking and managing changes to your database schema objects. Whether you are working on a small team or in a large organization, SQL Source Control can greatly improve your database development process.