De-select column for comparison, but still include it in INSERT
BHughes
Posts: 7 New member
I have a situation where I might like to exclude a column from the comparison, but still want it included in a resulting INSERT statement that is ultimately deployed. The column itself is meaningless for what I'm doing and I don't want updates to it triggering downstream processes, but when I exclude it from the compare, it is skipped in the resulting insert statement generated for new records. Since the column is defined as NOT NULL, I'll need to assign a default or make it nullable on the target.
I'm not entirely certain I want to go this route, but I was surprised when the column was excluded from the insert statement when I disabled it from comparison. I don't want a change to ONLY this column to trigger an update statement, but it still needs to be there on insert.
I'm not entirely certain I want to go this route, but I was surprised when the column was excluded from the insert statement when I disabled it from comparison. I don't want a change to ONLY this column to trigger an update statement, but it still needs to be there on insert.
Tagged:
Answers
When disabling a column via the 'Tables & Views' tab, it is disabled from both the comparison and subsequent deployment.
Sadly the feature in SQL Data Compare to remove a column from the comparison and still include it in the subsequent deployment, simply does not exist within the tool.
I recommend that you vote and comment on this UserVoice Forum Request. Hopefully, it maybe seen in a future version of SQL Data Compare.
Many thanks
Eddie
Senior Product Support Engineer
Redgate Software Ltd
Email: support@red-gate.com