Cmd Line: objects are identical or no objects selected
SeaSharp
Posts: 10
I'm trying to execute a sqlcompare from the command line, like so...
1. Creating the project, executing the compare then saving the SCP.
2. Creating the project, saving the SCP then executing the compare.
I'm not having any luck. I'm using SQL Compare 9.0.0.79 Professional Edition from the Sql Developer Bundle.
Thanks
sqlcompare /Project:"C:\Whatever.scp"It returns the error message, "The selected objects are identical or no objects have been selected in the comparison." The DB's are not identical & the compare successfuly shows this when using the SQL Compare desktop. Yes, I did see this post which states that "you'll need to run a comparison, check the boxes, and save the project." That isn't working for me. I've tried...
1. Creating the project, executing the compare then saving the SCP.
2. Creating the project, saving the SCP then executing the compare.
I'm not having any luck. I'm using SQL Compare 9.0.0.79 Professional Edition from the Sql Developer Bundle.
Thanks
Comments
:roll:
Let us know if you have any other problems.
To synchronize, you have to specify the /sync switch.
What differences are being reported in the GUI? Are the objects listed in any of the 'objects with differences' groups in the top of the results grid, or are the differences only noticed in the SQL Differences pane at the bottom of the screen?
+ 102 objects that exist in both but are different
+ 2 objects that exist only in <ServerName>.<DatabaseName>
+ 808 identical objects
All of the 102 differences are found in stored procedures. When I click the stored procedure name it brings up the SQL pane and highlights the difference in green. They are definitely different.
This is what the compare looks like when executed from the command line:
C:\Program Files (x86)\Red Gate\SQL Compare 9>sqlcompare /s1:MySourceServer /db1:MyDB /s2:MyTargetServer /db2:MyDB /options:default
Does the problem remain if you create a brand new project file?
Also, could you try using the /Include:Indentical switch with the project file?
If neither of these make a difference, would you be able to send me a SQL Compare snapshot of the source and target schemas, and also the project file?
I should then be able to recreate the project here.
I created a new project file from scratch. It still had the same problem
Unfortunately, I cannot send the schema because it is a sensitive problem domain related to safety & security. I realize that limits your ability to help me. Perhaps I can try to reproduce the problem with a new mock database. I'll see what I can do.
You also might like to try using an XML arg file instead of the project file as a workaround. You reference the arg file like you reference the project file, but it's not as easy to create as there isn't a UI for it.
Error: The selected objects are identical or no objects have been selected in
the comparison.
I tried adding the include statement to my xml document but I want to use 3 types in my include statement so I get differences, missing and add but when I put that in my xml file I get this error.
Error: The /include and /project or /filter switches cannot be specified
together with anything other than /include:identical