Comments
4 comments
-
Thanks for your post.
I've just tried to recreate this and I was able to use both /scriptfile and /sync together.
Did you set the /force switch so that you can overwrite the existing script file?
If this doesn't help, can you post the command you are using? -
Using the "/force" switch with the other switches works a treat - I no longer get the error message and changes are synchronised and save to the script file.
Thanks a lot - now all I need to SQL Source Control to allow my devs to source control data! -
We're hoping to put static data support in SQL Source Control in the next major release. In the meantime you'll have to do this via SQL Data Compare Pro:
http://www.red-gate.com/supportcenter/C ... aspx?p=SQL Source Control&c=SQL_Source_Control/help/1.0/SSC_Source_Controlling_Data.htm&toc=SQL_Source_Control/help/1.0/toc.htm
If you try this, you'll need the latest patched build:
http://www.red-gate.com/MessageBoard/vi ... hp?t=10917
Regards,
David -
I got the same problem with SQL Compare v 8. It writes the file out when it does the comparison, and then tries to write it out again a second time, but aborts when it finds to its surprise that the file is already there. If you nick out the /synchronize switch it seems to work.
Add comment
Please sign in to leave a comment.
I want to apply the changes to our test database from subversion (using the "/synchronize" switch), AND save the resulting script file as artifacts of the build for future reference (using the "/scriptFile" switch).
When I use both of these switches, SQLCompare tries to write to the script file twice, one for the /scriptFile switch and one for the /synchronize, and outputs an error:
Registering data sources
Creating mappings
Comparing
Applying project settings
Creating SQL
Creating SQL
Error: Unable to write migration script to file '...' because the file already exists.
Is this a bug? Is there a way for me to both synchronize and save a script file without having to run the command line twice?