Click here to monitor SSC
SQLServerCentral is supported by Redgate
Log in  ::  Register  ::  Not logged in

Using Views

By Steve Jones,

There are so many ways to undertake development inside of SQL Server. The growth of the platform has given us many options for solving problems and implementing features. However fundamentally altering schemas has continued to be problematic and challenging for many database developers.

Many applications are tightly tied to the underlying schema, and changing columns or tables is often so difficult that developers hesitate to make changes. Migration scripts help, but they must be manually created and are still daunting enough that many developers still avoid making changes that are potentially destructive. 

I was watching a session recently on another topic, but as part of the demo, there were changes being made to the schema while an application continued to insert and update rows without breaking. I've rarely seen people bother with this, but I'm wondering how many of you use this technique:

Are you using views to allow schema changes?

The demo showed the rename of a table and the creation of a view to allow an application to continue to work with minimal delays. A well designed application that retries batches wouldn't flinch at this change. Once it's complete, further schema alterations like horizontal/vertical partitioning can occur seamlessly.

I used this technique back in v6.5, but there were problems scaling views and I've been hesitant to try it since. However the performance of SQL Server has vastly improved and I'm interesting in whether or not others are using this regularly to upgrade their applications without downtime.

Total article views: 311 | Views in the last 30 days: 1
Related Articles

Continuous Delivery

The practice of continuous software development is growing, with continuous integration, deployment,...


Continuous Integration with Microsoft SQL Server

What about database development? In most projects, developers aren’t focused on database development...


Merging schema changes from server db to client db

Issues while merging schema changes


DB Snapshots - Schema changes backed up?

DB Snapshots - Schema changes backed up?


Schema Sandbox

Establish developer sandbox using schemas