Red Gate forums :: View topic - A duplicate object name has been found. This may occur if th
Return to www.red-gate.com RSS Feed Available

Search  | Usergroups |  Profile |  Messages |  Log in  Register 
Go to product documentation
SQL Compare 10
SQL Compare 10 forum

A duplicate object name has been found. This may occur if th

Search in SQL Compare 10 forum
Post new topic   Reply to topic
Jump to:  
Author Message
moviancp



Joined: 08 Jul 2014
Posts: 2

PostPosted: Tue Jul 08, 2014 9:34 am    Post subject: A duplicate object name has been found. This may occur if th Reply with quote

I am having troubles we comparing a specific source database in SQL Compare 10.7. The source database is not case sensitive, and contains several schemas, some table names exists is multiple schemas.

Previously this was not an issue for SQL Compare, however today i start receiving the following error:
A duplicate object name has been found. This may occur if the SQL Server that you are registering is case sensitive but the case sensitive option is not set.

But as mentioned above the database is not case sensitive. How do a cope with this error. I find it strange that it is not reporting the actual name of the object that resulted in the conflict - how can I figure this out?

Extract of log:
Code:

10:26:58.958|Error  |SQL Compare Engine  |13 |SqlCompareException: A duplicate object name has been found. This may occur if the SQL Server that you are registering is case sensitive but the case sensitive option is not set.
System.ArgumentException: Der findes allerede et element med samme nøgle.
   ved System.ThrowHelper.ThrowArgumentException(ExceptionResource resource)
   ved System.Collections.Generic.SortedList`2.Add(TKey key, TValue value)
   ved #8rg.#Ssg.#Klh()
   ved #8rg.#Ssg.#vl(DBPopulationOptions #WXrc)
10:26:59.093|Error  |SQL Compare UI      |1  |Exception in progress dialog
RedGate.SQLCompare.Engine.SqlCompareException: A duplicate object name has been found. This may occur if the SQL Server that you are registering is case sensitive but the case sensitive option is not set. ---> System.ArgumentException: Der findes allerede et element med samme nøgle.
   ved System.ThrowHelper.ThrowArgumentException(ExceptionResource resource)
   ved System.Collections.Generic.SortedList`2.Add(TKey key, TValue value)
   ved #8rg.#Ssg.#Klh()
   ved #8rg.#Ssg.#vl(DBPopulationOptions #WXrc)
   --- Slut på staksporing af indre undtagelser ---
   ved #8rg.#Ssg.#vl(DBPopulationOptions #WXrc)
   ved #8rg.#AHud.Register(ConnectionProperties #Ap8b, Options #5OPb)
   ved RedGate.SQLCompare.Engine.Database.Register(ConnectionProperties connectionProperties, Options options)
   ved RedGate.SQLCompare.Common.CompareEngineExecutor.DoRegisterDatabaseForCompare(Database #RHc, LiveDatabaseSource #ovUb)
   ved RedGate.SQLCompare.Common.CompareEngineExecutor.DoRegisterDatabaseForCompare(Database #RHc, DataSource #ovUb)
   ved RedGate.SQLCompare.Common.CompareEngineExecutor.#7bH()
   ved RedGate.Shared.Utils.ProgressTasks.ProgressTask.#kco()
   ved RedGate.Shared.Controls.ProgressDialogEx.DoTasks()
Back to top
View user's profile Send private message
Admin
Site Admin


Joined: 15 Aug 2004
Posts: 9

PostPosted: Thu Jul 10, 2014 2:06 pm    Post subject: Reply with quote

Hello,

Sorry this is not straightforward, and depends on what is being compared. If it's a live datasource, this should not happen as SQL Server does not allow two objects of any type with the same name. In that case, possibly the database is corrupt.

With scripts folders, you can use MS-DOS findstr (findstr /S /I /C:"object name" *.*) The reason this happens is usually CI-related - either someone has put a scripts folder as a subfolder of a scripts folder, put "migrations" scripts inside the scripts folder, or specified two VCS roots containing scripts, which then combine into the same folder.
Back to top
View user's profile Send private message Send e-mail
moviancp



Joined: 08 Jul 2014
Posts: 2

PostPosted: Tue Jul 29, 2014 6:59 am    Post subject: Update Reply with quote

It happens in a database to database compare.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic All times are GMT + 1 Hour
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group