Options

How to get the detail of a difference

WimCoppenolleWimCoppenolle Posts: 2
edited July 31, 2007 6:13AM in SQL Toolkit Previous Versions
Hi,

How do you get the exact difference between two tables after a compare of the databases?
For instance, a difference in the differences collection has a type of different. This is nice to know, but how do you know what the exact difference is (for instance, a field is missing).

Tx!!!

Comments

  • Options
    Hi,

    How do you get the exact difference between two tables after a compare of the databases?
    For instance, a difference in the differences collection has a type of different. This is nice to know, but how do you know what the exact difference is (for instance, a field is missing).

    Tx!!!

    Hi,

    once you know that a table is different, you will need to examine each individual component to detect differences. There could be many differences.
    The equality check methods are named "Equals" and all database objects support them.
    In case of fields, you have to match them up, and call the Equals method for them. You can use options to ignore parts of them, like identities, etc.
    Similarly you will need to match and compare every trigger, check constraint, indexes.

    In the case of permissions, the permissions collection has a general Equals method, so you do not need to match the individual objects.

    Regards,
    Andras
    András Belokosztolszki, PhD
    Red Gate Software Ltd.
Sign In or Register to comment.