Is Your Data Under Version Control?
The database is a critical part of your application. As well as holding code in the form of stored procedures, functions, views and triggers it also holds data. Many applications are highly configurable using metadata tables to manage application functionality. In such applications this data is as important as the code, however all too often this data is not under any form of source control.
The result is that changes get overwritten, the wrong data is deployed and environments are managed by copying databases. This often creates an error prone, inflexible and slow development life-cycle, with little or no audit capability and limited options for backing out changes.
This is why we developed DATASTAR which is a unique development tool to enable you to version database components including data utilizing your existing source control system. With DATASTAR you describe how you want to componentize your data and then use the software to generate scripts which encapsulates this data as components. The scripts are used to deploy to other environments so these would typically be placed under version control. DATASTAR will integrate with your version control system making it easy to package multiple changes into a release and enable you to deploy to multiple environments quickly and simply.
The result is that changes get overwritten, the wrong data is deployed and environments are managed by copying databases. This often creates an error prone, inflexible and slow development life-cycle, with little or no audit capability and limited options for backing out changes.
This is why we developed DATASTAR which is a unique development tool to enable you to version database components including data utilizing your existing source control system. With DATASTAR you describe how you want to componentize your data and then use the software to generate scripts which encapsulates this data as components. The scripts are used to deploy to other environments so these would typically be placed under version control. DATASTAR will integrate with your version control system making it easy to package multiple changes into a release and enable you to deploy to multiple environments quickly and simply.
CODE GENERATION
In many systems code is held in configuration and reference data tables. This data has historically been difficult to manage and migrate through the software development life-cycle. DATASTAR is unique in that it doesn't just version objects such as functions, procedures and triggers; its key feature is its ability to version data by generating scripts that encapsulate the data and their relationships with other tables. Internal identifiers and foreign key identifiers will typically differ between environments; the scripts that are generated automatically manage these identifiers using alternative or surrogate keys. The generated scripts do not contain transient values therefore different environments can be compared very easily using standard text based comparison tools to compare one set of scripts with another, the scripts themselves are self contained and can be read and understood by anyone who understands SQL. The level of granularity is configurable for each component allowing you decide whether to break data down into subsets or group into large datasets. Generally speaking the more granular the better as it avoids conflicts on components when you have a team working on multiple changes that could impact the same set of tables. |
DEPLOYMENT
Using a Source Control Management (SCM) System such as Subversion (SVN) or Team Foundation Server (TFS) the components generated can be placed under source control so that you start to build up a history of changes. DATASTAR integrates with your SCM System so that you can identify changes and package a deployment accordingly. This works by generating a deployment file using the change history in your SCM System, where necessary additional scripts can be triggered and other custom scripts included. The deployment file contains all the information about your release including the version number, scripts and order in which the deployment will be executed. Using the deployment file you can deploy the changes to any environment; other features support generating a backout deployment file, creating release notes using the SCM System History, and generating a SQL Script that encapsulates the deployment in a single file. The deployment process captures all the changes made and will create a log file that can be saved as part of the audit information for a deployment. All the scripts are re-runnable and can be safely reapplied to an environment. The scripts are designed to check whether changes are required avoiding unnecessary updates and providing more accurate audit information. |