Synchronizating with new NOT NULL columns
mihies
Posts: 71 Bronze 4
Hi guys,
If I add a NOT NULL column without a default value (I want application layer to generate the value) I can't synchronize database if there is any data in target table (it can't insert null values). Thats reasonable but not perfect.
I was thinking that I could enter a default value at synchronization time (into SQL Compare) and just for synchronization.
This would be a nice improvement for me...
What do you say?
If I add a NOT NULL column without a default value (I want application layer to generate the value) I can't synchronize database if there is any data in target table (it can't insert null values). Thats reasonable but not perfect.
I was thinking that I could enter a default value at synchronization time (into SQL Compare) and just for synchronization.
This would be a nice improvement for me...
What do you say?
Miha Markic [MVP C#, INETA Country Leader for Slovenia]
Blog:http://blog.rthand.com
Righthand .net consulting and software development
http://www.rthand.com
Blog:http://blog.rthand.com
Righthand .net consulting and software development
http://www.rthand.com
Comments
Thank you for your suggestion.
As you have already found if you add a NOT NULL column to a table that already contains data the synchronization fails if you do not set a default value.
I will submit your suggestion forward but I cannot guarantee that your suggestion will appear in later versions of software.
Best Regards
Eddie Davis
Red Gate Software Ltd
Technical Support Engineer
Senior Product Support Engineer
Redgate Software Ltd
Email: support@red-gate.com
I hope you'll add it. Otherwise is a hassle dealing with such cases.
Thanks,
Blog:http://blog.rthand.com
Righthand .net consulting and software development
http://www.rthand.com