Generate SQL change script

Answered

I have object definitions stored in multiple files that constitute the contents of a git branch. How can I compare one or all of these files to the corresponding objects in a database in order to generate change scripts?

For example I add a column to a table definition which is just a create statement. How would I generate an alter statement to update the table? Normally I just push my changes and the DevOps system produces and applies all the scripts to bring the target objects into line with the VCS, but it would be extremely helpful to do this for individual objects so I can test table changes in development without waiting or applying the changes manually.

I cannot see how in the documentation.

Thank you.

1 comment
Comment actions Permalink

You can create a DDL data source from your files, compare tables in DDL with dev database and generate update scripts.

0

Please sign in to leave a comment.