add If not exists to data compare
Any way of adding If not exists to the data script output when comparing data.
We've had to roll our own console app to wrap the Inserts with an If Exists. Not the best way to handle the situation. It would be nice if SQL Data Compare would do it automatically so that we don't have to clean up the generated script.
This is such a basic need for deployment in dev, test, and eventually production environments. Please add this feature.
What's the point of have a "User Voice" section if the most upvoted suggestion was not considered after so many years?
I upvoted, but its hard to believe this will ever be implemented if its gone ignored for over 6 years now...
We also deploy a meta database on a two week sprint, and then a quarterly release. The release is a combination of all the updates, and currently we have no good way to avoid insert conflicts unless we deploy the entire meta database during the quarterly release. I am currently investigating how to modify the Insert statements that SQL Data Compare creates to add an IF NOT Exists around them. It would be nice not to have to programmatically modify the results from SQL Data Compare in order to accomplish this. The tool should handle this for me.
Njama Braasch commented
script out a merge statement instead of a simple insert! Easy enough!
This would be very useful for us. We deploy DB changes as Hotfixes and Service Packs. A Service Pack rolls up changes of all Hotfixes since the last Service Pack, so we manually have to add existance checks - almost defeats the main use-case for SQL Data Compare for us.
Please add existance checks.
I am in shock this does not exist. Freeware tools to script data changes can check if not exists.
I too would love to see this. Right now, I take the script and split it in three parts:
a) Heading ALTERS
c) Trailing ALTERS
Then I execute a) and c) as block and split b) into lines, to be able to execute them ignoring errors,
Not nice but working ;-(
For such a simple request, it's mind-boggling that this has not been implemented, and is causing us to consider not buying your product.
without this feature automation seems a pain. Any progress on this?
Steve Haley commented
Would like this feature, Right now I'm having to go in to every INSERT INTO, and add a IF NOT EXISTS before each line. Use case: occasionally we distribute table entries "early" to select databases, but still want to include in main release scripts.
Also would be nice to have the "else" statement: if exists UPDATE the row with the values described in the INSERT
Tim Friesen commented
Would love to see this added. I manually have to add this to all deployment scripts I deploy.
Valthor Druzin commented
Any progress on this issue ?
Len Kalman commented
Just Checking Status on this request SDC-828.