Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Sam Walpole 2 posts 96 karma points
    Aug 02, 2021 @ 11:57
    Sam Walpole
    2

    Cant upgrade from Umbraco 8.14.1 to 8.15.1

    When I try to upgrade I get the following error:

    The database failed to upgrade. ERROR: The database configuration failed with the following message: 'FK_umbracoRedirectUrl_umbracoNode_uniqueID' is not a constraint. Could not drop constraint.
    

    I have checked my database and indeed this constraint does not exist. I have tried creating it myself using the following SQL:

    alter table [umbracoRedirectUrl]
    add constraint [FK_umbracoRedirectUrl_umbracoNode_uniqueID]
    foreign key ([id])
    references umbracoNode([uniqueId])
    

    This also gives an error:

    The ALTER TABLE statement conflicted with the FOREIGN KEY constraint "FK_umbracoRedirectUrl_umbracoNode_uniqueID". The conflict occurred in database "NesspointUmbraco", table "dbo.umbracoNode", column 'uniqueId'.
    

    Any help would be greatly apprciated.

  • peter_56 1 post 71 karma points
    Aug 04, 2021 @ 09:55
    peter_56
    0

    Hello,

    Please read the below article, It's may help you.

    https://www.gitmemory.com/issue/umbraco/Umbraco-CMS/10693/881426531

  • Patrik Andersson 2 posts 22 karma points
    Aug 09, 2021 @ 06:39
    Patrik Andersson
    0

    I have the same problem but from version 8.9.1 to 8.15.1, getting the same error as mentioned above.

  • Gabriel Robert 1 post 21 karma points
    Aug 09, 2021 @ 18:34
    Gabriel Robert
    0

    I have the same problem from 8.10.2 to 8.15.1.

  • Sjoerdson 1 post 21 karma points
    Aug 10, 2021 @ 09:23
    Sjoerdson
    0

    We also have this exact problem updating from 8.13.0 to 8.15.1.

  • atswebdevelopment 1 post 21 karma points
    Aug 12, 2021 @ 09:48
    atswebdevelopment
    0

    Same when updating from 8.8.0 to 8.15.1

    Edit: Tried updating to 8.10 - worked

    Updated to 8.12 - worked

    Updated to 8.14 - worked

    Updated to 8.15 or 8.15.1 - I get the above constraint error.

    DB is Azure, with no custom class code/routing.

  • auroris 3 posts 76 karma points
    Aug 12, 2021 @ 23:40
    auroris
    0

    I also have this problem, unable to go from 8.14.1 to 8.15.0 or 8.15.1.

    ERROR: The database configuration failed with the following message: 'FK_umbracoRedirectUrl_umbracoNode_uniqueID' is not a constraint. Could not drop constraint.

  • Miklos Kanyo 2 posts 72 karma points
    Aug 15, 2021 @ 12:59
    Miklos Kanyo
    0

    Same error here upgrading from 8.13.0 to 8.15.1

  • mmaty 114 posts 288 karma points
    Aug 17, 2021 @ 10:46
    mmaty
    0

    Same here 8.14.1 -> 8.15.2. Any insights?

    I created a fake constraint like that:

    ALTER TABLE umbracoRedirectUrl WITH NOCHECK
    ADD CONSTRAINT FK_umbracoRedirectUrl_umbracoNode_uniqueID CHECK (contentKey <> '') ;
    

    The installation seems to go over this problem, but shows another problem:

    The database failed to upgrade. ERROR: The database configuration failed with the following message: 
    An explicit DROP INDEX is not allowed on index 'umbracoNode.IX_umbracoNode_UniqueId'. 
    It is being used for UNIQUE KEY constraint enforcement. 
    

    Seems, as if the Upgrade to 8.15.x has some severe flaws.

    EDIT: I only see now, that @Sam tried the same thing and failed as well.

  • Sam Walpole 2 posts 96 karma points
    Sep 03, 2021 @ 13:18
    Sam Walpole
    102

    Thanks, this worked for me too. Here is the exact SQL I used:

    ALTER TABLE umbracoRedirectUrl WITH NOCHECK
    ADD CONSTRAINT FK_umbracoRedirectUrl_umbracoNode_uniqueID CHECK (contentKey <> '') ;
    
    ALTER TABLE umbracoNode
    DROP CONSTRAINT IX_umbracoNode_UniqueId
    
  • Bozhidar Aleksandrov 1 post 71 karma points
    Oct 04, 2021 @ 13:44
    Bozhidar Aleksandrov
    0

    This worked for me. Had the same error trying to upgrade from 8.13 to 8.16. Thank you!

  • mmaty 114 posts 288 karma points
    Aug 18, 2021 @ 13:48
    mmaty
    0

    That's how I managed the upgrade:

    I added the constraint like shown above in my first post. Don't add the constraint the same way it was originally intended, because it will block a following DROP INDEX statement.

    I removed the Index IX_umbracoNode_UniqueId of the umbracoNode table manually.

    After that the upgrade completed.

  • Patrik Andersson 2 posts 22 karma points
    Aug 26, 2021 @ 07:50
    Patrik Andersson
    0

    This solution worked for me aswell, thank you!

  • mmaty 114 posts 288 karma points
    Aug 26, 2021 @ 10:00
    mmaty
    0

    @Patrik: Glad to hear that!

  • Thomas 319 posts 606 karma points c-trib
    Sep 03, 2021 @ 07:26
    Thomas
    0

    Same with 8.14.3 to 8.16..

  • mmaty 114 posts 288 karma points
    Oct 05, 2021 @ 11:14
    mmaty
    1

    To recap the Solution: If you execute the following lines in SSMS, the database update continues without errors.

    ALTER TABLE umbracoRedirectUrl WITH NOCHECK
    ADD CONSTRAINT FK_umbracoRedirectUrl_umbracoNode_uniqueID CHECK (contentKey <> '') ;
    
    ALTER TABLE umbracoNode
    DROP CONSTRAINT IX_umbracoNode_UniqueId
    
Please Sign in or register to post replies

Write your reply to:

Draft