Excluding column compares

DennisRehmDennisRehm Posts: 13 Bronze 2
I like the feature that row comparisons can be done on a limited number of columns. This is useful where columns may be updated by triggers and contain LastTimes. However, it appears that when I limit the comparison to specific columns, if a row exists in one table but not the other, only the compared column values are used for the INSERT. Unfortunately, if the column does not allow NULLs, the INSERT fails. I'd like to do the comparison on the specified columns and update only those columns if they differ. However, if one row exists in the source table and not in the target table, I'd like all columns to be inserted.

Thanks,
Dennis

Comments

  • Hi Dennis,
    Glad you like the "limiting the number of columns" feature. However as you have seen this also effects the update and insert SQL. I will put this on the candidate list to be considered for a future Data Compare release.
    Regards
    David.
This discussion has been closed.