Redgate Sql Data Compare

Posted on by  admin

I actually use Redgate Data Compare every day a long time, this software used with his 'brother' SQL Compare (used to compare DB structures) forms the winning pair for fast and simple control of DB and data structures (intended for each record, column by column) between different environments of development.

Sql

I realized today that much of VSTS Database Professional is simply an import of Red-Gate SQL Compare as a VS add-in. That said, then perhaps Red-Gate or Microsoft one, could heed this suggestion. I just ran the script for a database update into a production server. There were 100+ steps in the script. One of them failed. There is no way to tell which one it was.

There were no displayed error messages. There were a couple warnings about a table whose row width was 8142 - that certainly should not have broken the script. The problem comes down to the error handling mechanism in these scripts, both for Red-Gate SQL Compare and for VSTS Database Professional. Because, in the event of an error, the current transaction is rolled back, a new transaction begun, and the script just continues on its merry way. If you were to follow the recommendations in this article,, and precede each action statement with IF @@ERROR = 0, then in all cases, last print statement in the script would tell you what was being done when the failure happened. Alternatively, I suggest that you set a variable with the current action before attempting the action and, if you have to rollback the transaction, print a line describing the action that failed.

Redgate Sql Data Compare

Thanks, Dale Preston MCSE, MCAD, MCDBA.

Comments are closed.