Copied to clipboard

Flag this post as spam?

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


  • Thanh Pham 23 posts 140 karma points
    Dec 14, 2017 @ 03:40
    Thanh Pham
    0

    Getting error when upgrading Umbraco to version 7.7.6

    Can anyone shed some lights on the issue I'm facing as below? I'm upgrading Umbraco CMS from version 7.5.6 to 7.7.6 and getting an error regarding FOREIGN KEY constraint:

    The database failed to upgrade. ERROR: The database configuration failed with the following message: The INSERT statement conflicted with the FOREIGN KEY constraint "FKumbracoUserGroup2NodePermissionumbracoNodeid". The conflict occurred in database "SubaruGroupUmbraco14122017", table "dbo.umbracoNode", column 'id'. The statement has been terminated. Please check log file for additional information (can be found in '/App_Data/Logs/UmbracoTraceLog.txt')

    enter image description here

    Thanks.

  • Steve Morgan 1348 posts 4457 karma points c-trib
    Dec 14, 2017 @ 10:15
    Steve Morgan
    0

    Hi,

    Sounds like a db user in your web.config that isn't SA.

    This upgrade drops some tables so the SQL user needs admin privileges.

    https://our.umbraco.org/forum/using-umbraco-and-getting-started/89324-ugrading-to-776-invalid-object-name-umbracouser2usergroup

    HTH Steve

  • Thanh Pham 23 posts 140 karma points
    Dec 15, 2017 @ 03:47
    Thanh Pham
    100

    Hi Steve,

    My db user has admin privileges so I don't think it's not the issue. Also my other wesbites using the same db user have no issue when upgrading to Umbraco 7.7.6.

    Only manually ran the script below solved the problem as per the suggestion from the link you provided. Thank you.

    I'm using MS SQL SERVER.

    CREATE TABLE [dbo].[umbracoUserGroup2NodePermission]( [userGroupId] [int] NOT NULL, [nodeId] [int] NOT NULL, [permission] nvarchar NOT NULL, CONSTRAINT [PKumbracoUserGroup2NodePermission] PRIMARY KEY CLUSTERED ( [userGroupId] ASC, [nodeId] ASC, [permission] ASC )WITH (PADINDEX = OFF, STATISTICSNORECOMPUTE = OFF, IGNOREDUPKEY = OFF, ALLOWROWLOCKS = ON, ALLOWPAGE_LOCKS = ON) ON [PRIMARY] ) ON [PRIMARY]

    GO

Please Sign in or register to post replies

Write your reply to:

Draft