SQL Delta Logo
SQL Delta Banner

Feature Request

You can provide feedback to our developers

Feature Request

Postby sspayne » Tue Apr 01, 2008 7:25 pm

Not sure if this is the right place for it, but it seemed as good a place as any.

Currently, my company has been using SQL delta to create scripts that are used to upgrade multiple databases for different customers on the same platform between point releases.

However, one issue that we've not been able to address with SQL delta (and hoping we can in the future) is to add some logic into the updates done.

For instance, SQL delta already has a check to see if tables exist in the datbase before dropping them. What I'm looking for is the ability to specify more advanced logic:

1. For DDL changes:
  • For all drop statements, check to see if there is data in the table
  • For all add statements, check to see if it exists first.
  • For all alter statements, check for data in the columns dropped/check to see if a column exists first.

2. For DML changes:
  • For all INSERT statements, check to see if the primary key(s) exists.
  • For all DELETE statements, check to see if the <date> matches with the timestamp of the update.
  • For all UPDATE statements, check to see if the <date> matches with the timestamp of the update.


In all cases where the records exist/timestamps don't match, etc - it would issue a warning and not execute the statement.

The end goal here is to not update something that has been updated on the target database independantly of the point releases, to not delete data in tables that might have become obsolete, etc.

If something like this already exists for SQL delta - please do let me know because I haven't found it.

Currently, I am looking at implementing a post-processing solution - but it would be far easier for me to have it connected directly into SQL delta.
sspayne
 
Posts: 2
Joined: Wed Mar 26, 2008 6:23 pm

Postby david » Tue May 06, 2008 11:42 pm

For the DDL we are looking at adding these features.

For the DML would a pre and post "event" feature be of more assistance.

A thought is we provide a way of you adding the code you wish to execute before and/or after the Delta script. That way the code could be customized to your requirements.
david
Site Admin
 
Posts: 423
Joined: Mon Nov 10, 2003 11:22 pm

Postby sspayne » Thu May 08, 2008 7:33 pm

Excellent to hear about the DDL feature.

For the DML - yes a Pre and Post feature would work quite well.
sspayne
 
Posts: 2
Joined: Wed Mar 26, 2008 6:23 pm


Return to Feedback