This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

SafeGuard 7 to 8 - Database Migration Error

When migrating my database from 7 to 8 - I receive the following error:

Create Box Cloud Storage Definition
Msg 2627, Level 14, State 1, Line 12
Violation of UNIQUE KEY constraint 'UC_CLOUD_STORAGE_DEFINITION_NAME'. Cannot insert duplicate key in object 'dbo.CLOUD_STORAGE_DEFINITION'. The duplicate key value is (Box).

Any direction on what needs to be edited in current Database to resolve the error?

DB Migration Script:

/* Create 'Box' Cloud Storage Definition */
PRINT N'Create Box Cloud Storage Definition'
DECLARE @ValCreatedBy NVARCHAR(256)
DECLARE @ValCreationDate DATETIME

SELECT @ValCreatedBy = 'SQL migration script from 7.00 to 8.00'
SELECT @ValCreationDate = GETUTCDATE()

IF ((SELECT CSD_ID FROM CLOUD_STORAGE_DEFINITION WHERE CSD_ID='0x4D9013836AA34E22B4A5EAD5F2A54C86') IS NULL)
BEGIN
INSERT CLOUD_STORAGE_DEFINITION (CSD_ID,CSD_NAME,CSD_SYNC_APP,CSD_SYNC_FOLDERS,CSD_BLOCK,CSD_CREATION_DATE,CSD_MODIFY_DATE,CSD_CREATED_BY,CSD_MODIFIED_BY,CSD_CHECK_SUM)
VALUES ('0x4D9013836AA34E22B4A5EAD5F2A54C86','Box','<!Box!>','<!Box!>',null,@ValCreationDate,null,@ValCreatedBy,null,null)
END
GO



This thread was automatically locked due to age.
Parents
  • FormerMember
    0 FormerMember

    Hello EAA729,

    Looking at the error message it appears that you're trying to insert a key that is already contained in the database - is 'Box' or its key already defined in the database?

Reply
  • FormerMember
    0 FormerMember

    Hello EAA729,

    Looking at the error message it appears that you're trying to insert a key that is already contained in the database - is 'Box' or its key already defined in the database?

Children
No Data