Upload
red-gate-software
View
258
Download
0
Embed Size (px)
Citation preview
A Practical Approach to
Version Control for SQL ServerSteve Jones
SQLServerCentral
Redgate Software
#SQLintheCityUK
Goals
• Store database code in version control
• Track code changes across time
• Branch and merge changes to database
code
#SQLintheCityUK
Learn, Grow, Adapt
07/10/15 sqlrelay.co.uk/ Nottingham
08/10/15 sqlrelay.co.uk/ Reading
12/10/15 sqlrelay.co.uk/ London
13/10/15 sqlrelay.co.uk/ Bristol
14/10/15 sqlrelay.co.uk/ Cardiff
15/10/15 sqlrelay.co.uk/ Birmingham
Get in touch
www.voiceofthedba.com
@way0utwest
Steve Jones
#SQLintheCityUK
What is version control?…any kind of practice that tracks and provides control over changes to source code. Software developers sometimes use revision control software to maintain documentation and configuration files as well as source code.
(Wikipedia)
Source Control = Version Control = Revision Control
#SQLintheCityUK
Getting Started
• Create a location in a VCS respository
• Script out objects to .sql files
• Commit files
#SQLintheCityUK
Benefits
• Communication and collaboration
• History
• Undo
• Get back to previous versions
• Branching/merging
• Single version of the truth
• Building block for ALM
#SQLintheCityUK
Teamwork
• Work should be logically separated
• Sandboxes should to be used
• Developers’ work should not conflict
But sometimes we work on shared
databases, and …
#SQLintheCityUK
Finally
• Use a VCS, keep control of your code
• Ensure everyone has the tools
• Ensure everyone understands the process
• Write comments for the future you
#SQLintheCityUK
Goals
• Store database code in version control
• Track code changes across time
• Branch and merge changes to database
code
#SQLintheCityUK
Want to try the tools you’ve just seen?Head to the Hands-on Labs
Questions?
[email protected] @way0utwest
#SQLintheCityUK