WHITEPAPER. Improving database development



Similar documents
Improving database development. Recommendations for solving development problems using Red Gate tools

Continuous integration for databases using Redgate tools

Continuous integration for databases using Red Gate tools

Continuous integration for databases using

Visual Studio Team Edition for Database Professionals. Woody Pewitt Developer Evangelist

Key Benefits of Microsoft Visual Studio Team System

SQL DBA Bundle. Data Sheet. Data Sheet. Introduction. What does it cost. What s included in the SQL DBA Bundle. Feedback for the SQL DBA Bundle

WHITEPAPER. Solving database deployments with Database Lifecycle Management

Nick Ashley TOOLS. The following table lists some additional and possibly more unusual tools used in this paper.

Contents. Introduction... 1

WHITEPAPER. Compliance: what it means for databases

Tracking Database Schema Changes. Guidelines on database versioning using Devart tools

Tech Notes. Corporate Headquarters EMEA Headquarters Asia-Pacific Headquarters 100 California Street, 12th Floor San Francisco, California 94111

Effective Release Management for HPOM Monitoring

PRESENTS... Reasons to Switch from SourceSafe: How to Make Your Life Easier with SourceAnywhere Standalone

Distributed Software Development with Perforce Perforce Consulting Guide

Server Monitoring: Centralize and Win

Continuous Integration (CI)

CASE STUDY LUMIDATA. SQL Toolbelt. Essential tools for SQL Server. 91% of Fortune 100 companies use Red Gate

5 barriers to database source control and how you can get around them

About database backups

Orchestrated. Release Management. Gain insight and control, eliminate ineffective handoffs, and automate application deployments

Automated Testing Best Practices

Solving the database deployment problem

Life Cycle Management for Oracle Data Integrator 11 & 12. At lower cost Get a 30% return on investment guaranteed and save 15% on development costs

QlikView 11 Feature Sheet Source Control Integration

How To Manage Content Management With A Single System

The Benefits of a Unified Enterprise Content Management Platform

Overview. Datasheet: Centerprise Connector for Salesforce. Key Features. Overview

ATTACHMENT 6 SQL Server 2012 Programming Standards

Manual Tester s Guide to Automated Testing Contents

Agile Business Suite: a 4GL environment for.net developers DEVELOPMENT, MAINTENANCE AND DEPLOYMENT OF LARGE, COMPLEX BACK-OFFICE APPLICATIONS

Case Study - MetaVis Migrator

Development Best Practices

Backing Up CNG SAFE Version 6.0

RapidStart Implementation

Print Audit 6 Network Installation Guide

Top Ten Reasons to Transition Your IT Sandbox Environments to the Cloud

Streamlining Your AP Processes with Electronic Document Management

Software Configuration Management Best Practices

Copyrighted , Address :- EH1-Infotech, SCF 69, Top Floor, Phase 3B-2, Sector 60, Mohali (Chandigarh),

Invest in your business with Ubuntu Advantage.

CASE STUDY FINANCE. Republic Bank - Searching SQL Server databases, a typical quest begins...

Librarian. Integrating Secure Workflow and Revision Control into Your Production Environment WHITE PAPER

Nexus Professional Whitepaper. Repository Management: Stages of Adoption

Protecting Business Information With A SharePoint Data Governance Model. TITUS White Paper

Green Migration from Oracle

Using Colligo Contributor to Migrate Lotus Notes Applications to SharePoint

Using ExtraView to Consolidate Multiple Tracking Systems

DATABASE VIRTUALIZATION AND INSTANT CLONING WHITE PAPER

In depth study - Dev teams tooling

Zero-Touch Drupal Deployment

Best Practices for Migrating from Lotus Notes to Microsoft Exchange and SharePoint

W H I T E P A P E R S A P E R P L i f e - C y c l e M a n a g e m e n t O v e r c o m i n g t h e D o w n s i d e o f U p g r a d i n g

Application Development With Data Studio

Subversion Integration for Visual Studio

Microsoft Visual Studio Integration Guide

Universal Controller Solution Brief

WHITEPAPER. SBM Path to Production for Enterprises

Benefits of databases

Leveraging Rational Team Concert's build capabilities for Continuous Integration

Comparison: Perforce and Microsoft Team Foundation Server (TFS)

Microsoft. Course 20463C: Implementing a Data Warehouse with Microsoft SQL Server

We ( have extensive experience in enterprise and system architectures, system engineering, project management, and

How to Prepare for the Upgrade to Microsoft Dynamics CRM 2013 (On-premises)

Improving Cognos Upgrades Methodology to Lower Costs & Improve Upgrade Management

The Benefits of Deployment Automation

Development Lifecycle Guide

CONTENT STORE SURVIVAL GUIDE

The Benefits of Utilizing a Repository Manager

Microsoft Enterprise Project Management 2010 Licensing Guide

Marathon Information Management Program

Global Software Change Management for PVCS Version Manager

Increasing Business Efficiency and Agility for ATGbased. Systems. the business challenge: upgrading the development pipeline

White Paper. Securing and Integrating File Transfers Over the Internet

Implementing Oracle BI Applications during an ERP Upgrade

What s New Guide: Version 5.6

How To Benefit From An Automated Deployment

Continuous Integration

Autodesk Vault 2016 What s new

MySQL Enterprise Edition Most secure, scalable MySQL Database, Online Backup, Development/Monitoring Tools, backed by Oracle Premier Lifetime Support

IBM Software InfoSphere Guardium. Planning a data security and auditing deployment for Hadoop

ROI EVALUATION REPORT REPLIWEB DEPLOYMENT

Data Warehouse and Business Intelligence Testing: Challenges, Best Practices & the Solution

Implementing a Data Warehouse with Microsoft SQL Server

For Midsize Organizations. Oracle Product Brief Oracle Business Intelligence Standard Edition One

Simplifying development through activity-based change management

QlikView 11 Source Control Walkthrough

White Paper. Streamlining Your AP Processes with Electronic Document Management ABSTRACT. Command Your Content

Transcription:

WHITEPAPER Improving database development

Introduction At Redgate, we believe in creating simple, usable tools that address the problems of software developers and technology businesses. In considering the entire database development process we observed a number of costly, time-consuming, and highly obstructive problems that keep developers and businesses from working efficiently. This paper gives an overview of the problems of database development, particularly those of change management and migration. It outlines the typical Develop, Test, Deploy structure of database development, proposes improvements at each stage of the process, and introduces a source control solution that finally places databases on a par with application development. These recommendations are particularly relevant to development teams and businesses seeking to increase development efficiency, for instance to eliminate a backlog of highpriority, mission-critical development work. Crucially for these teams, the paper describes a complete database development package that integrates with existing working practices. 2

The development cycle The standard database development process has three core stages: 1. Develop The development team updates the database. Ideally, changes are source controlled. This enables tracking, and eases continuous integration. However, source control for databases is not yet widely adopted. 2. Test Migration scripts are created to move development changes to realistic testing and staging environments. The QA or Testing team ensure there are no bugs or regressions. 3. Deploy If testing is successful, migration scripts are created to deploy the changes to a staging environment, and then to production servers. These final deployment scripts are typically scrutinized and ultimately run by a DBA. The database development cycle is similar to that for application code, but with some crucial difficulties. For instance, there is often no source control; versioning is cumbersome; dependency chains can be complex and opaque; and the very nature of database code makes deployment a significant bottleneck. Each stage in the cycle typically involves substantial manual scripting and a change management overhead. Each stage also has inefficiencies, and can be automated or made simpler, reducing errors and easing coordination. This whitepaper seeks to address these issues, and offer solutions using the Redgate SQL Developer Suite. 3

The problem of change management Even in a small project, where a single developer is modifying a simple database, changes can introduce bugs and regressions. The more complex the development effort, the more likely it is that changes will have unforeseen consequences. Source control is the solution typically adopted in application development. It allows teams and managers to see what was changed, when, and by whom; as well as offering a sandbox, versioning, and rollback. When more than one developer is making modifications to a database, the whole team has all of these benefits. Sandboxes, in particular, are important, as they allow an individual developer to explore potentially breaking changes without disrupting the work of the team. However, team development introduces the possibility of conflicts. Source control systems make it easier to find and resolve them. 4

The difficulty of database source control In application development, source code is kept under in source control so that each revision to a file is retained. However, database development is generally done by working directly with a database, rather than with script files. DML and DDL queries modify the current state of a database, so there are no files being changed. There is therefore no source code to control. Most existing methods for source controlling databases are workarounds. Source code is created artificially by scripting out database objects, or storing migration scripts - and this sits outside the database development cycle. Within the development workflow, scripts may be specifically created for migration and deployment, and those scripts can be checked into a source control repository. However, deployment scripts do not represent a practical history of incremental changes, and creating them regularly complicates the development process. Mature development projects will already employ a source control system. Finding a simple way to record database modifications in that system solves the change management problem by taking greater advantage of your existing infrastructure. So there is no need for an additional investment. 5

With Redgate tools, the database development process becomes simpler and more unified. Database changes are source controlled alongside application code, where both can be versioned and become part of a continuous integration process. Tests can be run, and readily automated, as can schema documentation, and eventual deployment. The result is that higher quality development becomes easier, and requires less developer time. 6

Improving the development environment SQL Server Management Studio is central to the SQL Server development and administration process. It is the industry standard IDE. There are alternatives - notably Visual Studio, used for developing application code - but they are not so closely tailored to database development. As SQL Server Management Studio is the preferred and recommended IDE, it makes sense to introduce productivity and process enhancements directly into that environment. Switching between tools is disruptive, and purchasing a new IDE is disruptive and costly. The Redgate SQL Developer Suite integrates directly with SQL Server Management Studio, to address two problems: individual productivity, and team processes. 7

Productivity improvements The majority of database development time is, unsurprisingly, spent writing and maintaining SQL code, so this is the most obvious productivity bottleneck to address. SQL Prompt is a code auto-completion and layout tool. This makes writing SQL faster and more reliable. SQL Prompt also helps developers with code maintenance. It lets you automate table splits, renames, and other common, time-consuming refactorings. A modern database may contain hundreds if not thousands of objects, so writing code is only part of the productivity problem. Even with easily adopted naming conventions, just finding a specific object, or an object that references another can take time. SQL Search searches for SQL code across one or more databases, making it easier to work with large, complex schemas. 8

Process improvements The cornerstone of Redgate's database development process recommendations is the introduction of source control. Once source control is in place, it is easier to adopt continuous integration and unit testing. These are established best practice for application code, but have so far not been readily available for database development. SQL Compare Pro and SQL Data Compare Pro simplify migration and deployment, which in turn enables automation, when used with Redgate s DLM Automation Suite.. Automated deployments, and the realistic data generation provided by SQL Data Generator make it easy to adopt database unit testing, as well as performance and integration tests. 9

Redgate's source control solution SQL Source Control is Redgate's source control solution. It integrates your existing source control system with the database development workflow. SQL Source Control is an add-in for SQL Server Management Studio. It maintains a folder of scripts representing the structure of a database in source control. Database source control can therefore easily be adhered to, as the day-to-day steps such as committing changes have been simplified and brought into the existing workflow. 10

Advantages of SQL Source Control The benefits of database source control are the same as the benefits of source control for application code. You can audit changes, seeing when, by whom, and why they were made. You can isolate those changes, and where necessary, roll them back. Each developer has a safe sandbox, changes are merged back into the central repository, and batches of changes can be collated into labeled versions. SQL Source Control is designed to eliminate the extra overhead of creating code to source control. Because it sits within SQL Server Management Studio and rapidly detects schema changes, committing those changes is simple and quick. The source control repository can therefore represent "the truth" - the latest version of the database incorporating all changes. Because SQL Source Control makes it easy to update a database with changes from source control, and commit changes to source control, it eliminates the need to create change scripts during development. On its own, this saves time and eases change management. Source control that is simple and unobtrusive is more likely to be used. Source control with a low barrier to entry is easier to adopt. Usable, accessible source control that sits within the existing development workflow is a cornerstone of good change management. 11

Conclusion Redgate's SQL Developer Suite presents an alternative to the traditional scenario in which database development is cumbersome, challenging, and out of step with application code. Adopting it improves productivity, change management, testing, and deployment, across the whole database development life cycle. You can download the SQL Developer Suite, with all the tools described in this paper, for a free 14 day trial here: www.red-gate.com/sql-developer-suite 12