Installation and deployment
Version 7.x > Installation and deployment > v. 6 to v. 7 SQL Errors View modes: 
User avatar
Member
Member
Jessica.Sandvold-anthro - 6/26/2013 3:54:16 PM
   
v. 6 to v. 7 SQL Errors
Hi,
When attempting to upgrade our system from 6 to 7 I am getting the following errors:

Running SQL script (upgrade_6_0.sql)
Failed to run SQLscript: The CREATE UNIQUE INDEX statement terminated because a duplicate key was found for the object name 'dbo.CMS_Role' and the index name 'IX_CMS_Role_SiteID_RoleName'. The duplicate key value is (anthro-2010---plant-work-process, 1).
The statement has been terminated.

Failed to run SQLscript: The CREATE UNIQUE INDEX statement terminated because a duplicate key was found for the object name 'dbo.CMS_UserRole' and the index name 'IX_CMS_UserRole_UserID_RoleID'. The duplicate key value is (130, 146).
The statement has been terminated.

Failed to run SQLscript: Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding.
SQL script applied.

User avatar
Kentico Legend
Kentico Legend
Brenden Kehren - 6/28/2013 7:34:26 AM
   
RE:v. 6 to v. 7 SQL Errors
You might check your roles and see if you have duplicate with the name like %anthro-2010---plant-work-process%. It appears there is a duplicate in the cms_userrole table with the values of user id 130 and role id 146.

User avatar
Kentico Support
Kentico Support
kentico_radekm - 7/1/2013 1:27:51 AM
   
RE:v. 6 to v. 7 SQL Errors
Hello.

FroggEye is correct about what to check in order to fix the problem. This inconsistency may happen if the upgrade process did not go well, e.g. the web site has not been stopped during the process. So, you can also try to re-upgrade from back-ups and make sure all steps are followed properly, or upgrade via KIM utility. Thank you.

Best Regards,
Radek Macalik