Create statement: A duplicate definition was found ..
rleon
Posts: 3
Hi,
I've looking around for an answer but I couldn't find it. I'm having the following problem:
On one server (srv1) I have an installation of SQL Source Control (with SVN), and in another server (svr2) I have installed SQL Compare. On srv2 I also have a process that triggers the execution of a .bat file every time a change has been committed on srv1. This .bat, calls "sqlcompare" in order to sync a database with the most recent changes in the SVN repository.
When I alter an stored procedure on srv1 and commit changes, SQL Source Control commits it with a CREATE statement instead of an ALTER statement, so when I compare both sources on srv2, a "A duplicate definition was found for the stored procedure" error is raised. The same problem occurs when I compare both sources using the SQL Compare GUI.
Is there any known workaround for this? Can I force sqlcompare to overwrite the procedure?
Regards,
Ricardo
I've looking around for an answer but I couldn't find it. I'm having the following problem:
On one server (srv1) I have an installation of SQL Source Control (with SVN), and in another server (svr2) I have installed SQL Compare. On srv2 I also have a process that triggers the execution of a .bat file every time a change has been committed on srv1. This .bat, calls "sqlcompare" in order to sync a database with the most recent changes in the SVN repository.
When I alter an stored procedure on srv1 and commit changes, SQL Source Control commits it with a CREATE statement instead of an ALTER statement, so when I compare both sources on srv2, a "A duplicate definition was found for the stored procedure" error is raised. The same problem occurs when I compare both sources using the SQL Compare GUI.
Is there any known workaround for this? Can I force sqlcompare to overwrite the procedure?
Regards,
Ricardo
Comments
What locations are you pointing to? If the comparison folders are a subfolder of the source-controlled ones for instance, you'd encounter this, as we parse the whole folder structure.
Redgate Software
Thanks
In the meantime, could you increase logging and mail the file over to us? To increase logging, right-click the SQL Compare main window title-bar, and choose "Minimum Log level", then "Verbose".
Re-start the program, then preoduce the error. Now right click again, locate the latest log, and mail it to support@red-gate.com with F0041796 in the subject line.
Thanks!
Redgate Software