Comments
4 comments
-
The switches you're looking for are /server1: and /server2: (or /s1: and /s2:). So your command line would look like the following:
sqldatacompare /server1:SERVERNAME /db1:WidgetStaging /server2:SERVERNAME /db2:WidgetProduction /ScriptFile:"C:\Scripts Folder\WidgetSyncScript.sql" -
cheers for that... even simpler for setting up a static project, you can use an existing project definition (saves server,db and unames and pwds and everything else) ie...
sqldatacompare /project:"C:\Documents and Settings\user\My Documents\SQL Data Compare\SharedProjects\LocalServercRemoteServer.sdc" /ScriptFile:"C:\Data\scripts\OutputSql.sql" -
Im trying the following from a batch file:-
cd "c:\program files\Red gate\SQL Data Compare 8"
sqldatacompare.exe /server1:INVERNESS\SQL2005 /db1:GREGSTEST_DEV /scr2:"C:\Documents and Settings\gsuttie\Desktop\SQL continuos\ScriptsFolder\GREGSTESTSCRIPTS"
/synchronize
pause
I have also tried /sync both erroring - where am i going wrong?
Thanks
Gregor -
Hi
Your syntax there looks fine to me - what is the error message you get when this fails?
Add comment
Please sign in to leave a comment.
sqldatacompare /db1:WidgetStaging /db2:WidgetProduction
/ScriptFile: "C:\Scripts Folder\WidgetSyncScript.sql"
how do i specify the server where the database is, i.e. somthing like this?
sqldatacompare /db1:SERVERNAME\WidgetStaging /db2:SERVERNAME\WidgetProduction
/ScriptFile: "C:\Scripts Folder\WidgetSyncScript.sql"