We're updating the issue view to help you get more done. 

DNN 7.4.0 Upgrade Reports Error at 25% of Installation

Description

On a typical well-maintained DNN 7.3.4 version I tried to upgrade that version using the DNN_Platform_07.04.00_Upgrade files and strictly following the typical upgrade procedure like always, as every upgrade version is been releaed.

The DNN_Platform_07.04.00_Upgrade files and sub-folders overwritten the old ones of the live installation.

http://intelibrain.gr/Install/UpgradeWizard.aspx URL is been used to fire up the upgrade process.

At 25% I'm getting the following nightmare long message:

25% ERROR occured - System.Data.SqlClient.SqlException (0x80131904): Cannot insert

duplicate key row in object 'dbo.CoreMessaging_NotificationTypeActions' with

unique index 'IX_CoreMessaging_NotificationTypeActions_Type'.
The statement has

been terminated.
at System.Data.SqlClient.SqlConnection.OnError(SqlException

exception, Boolean breakConnection)
at

System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception,

Boolean breakConnection)
at

System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning()
at

System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand

cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler,

TdsParserStateObject stateObj)
at

System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean

async)
at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult

result, String methodName, Boolean sendToPipe)
at

System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at

DotNetNuke.Data.SqlDataProvider.ExecuteScriptInternal(String connectionString,

String script)

/* Remove Review action and add Approve, Reject */
DECLARE

@NotificationTypeId INT
SELECT @NotificationTypeId = NotificationTypeId
FROM

dbo.CoreMessaging_NotificationTypes
WHERE Name = 'ContentWorkflowNotification'

IF @NotificationTypeId IS NOT NULL
BEGIN
/* Delete Review notification action

added int 7.3.0 */
DELETE FROM dbo.CoreMessaging_NotificationTypeActions WHERE

NotificationTypeId = @NotificationTypeId AND NameResourceKey = 'Review'

/* Add

Approve notification action */
INSERT INTO

dbo.CoreMessaging_NotificationTypeActions(
[NotificationTypeID],

[NameResourceKey],
[DescriptionResourceKey],
[ConfirmResourceKey],
[Order],

[APICall],
[CreatedByUserID],
[CreatedOnDate],
[LastModifiedByUserID],

[LastModifiedOnDate])
VALUES(
@NotificationTypeId,
'Approve',
'Approve',

NULL,
1,
'DesktopModules/InternalServices/API/ContentWorkflowService/Approve',

-1,
GETDATE(),
-1,
GETDATE()
)

/* Add Reject notification action */
INSERT

INTO dbo.CoreMessaging_NotificationTypeActions(
[NotificationTypeID],

[NameResourceKey],
[DescriptionResourceKey],
[ConfirmResourceKey],
[Order],

[APICall],
[CreatedByUserID],
[CreatedOnDate],
[LastModifiedByUserID],

[LastModifiedOnDate])
VALUES(
@NotificationTypeId,
'Reject',
'Reject',
NULL,

1,
'DesktopModules/InternalServices/API/ContentWorkflowService/Reject',
-1,

GETDATE(),
-1,
GETDATE()
)
END

System.Data.SqlClient.SqlException

(0x80131904): Cannot insert duplicate key row in object

'dbo.CoreMessaging_NotificationTypeActions' with unique index

'IX_CoreMessaging_NotificationTypeActions_Type'.
The statement has been

terminated.
at System.Data.SqlClient.SqlConnection.OnError(SqlException

exception, Boolean breakConnection)
at

System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception,

Boolean breakConnection)
at

System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning()
at

System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand

cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler,

TdsParserStateObject stateObj)
at

System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean

async)
at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult

result, String methodName, Boolean sendToPipe)
at

System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at

DotNetNuke.Data.SqlDataProvider.ExecuteScriptInternal(String connectionString,

String script)

/* Add action to Start Workflow Notification */
DECLARE

@NotificationStartWorkflowTypeId INT
SELECT @NotificationStartWorkflowTypeId =

NotificationTypeId
FROM dbo.CoreMessaging_NotificationTypes
WHERE Name =

'ContentWorkflowStartWorkflowNotification'
IF @NotificationStartWorkflowTypeId IS

NOT NULL
BEGIN
/* Add Submit notification action */
/* also uses the existing

Approve method */
INSERT INTO dbo.CoreMessaging_NotificationTypeActions(

[NotificationTypeID],
[NameResourceKey],
[DescriptionResourceKey],

[ConfirmResourceKey],
[Order],
[APICall],
[CreatedByUserID],
[CreatedOnDate],

[LastModifiedByUserID],
[LastModifiedOnDate])
VALUES(

@NotificationStartWorkflowTypeId,
'Submit',
'Submit',
NULL,
1,

'DesktopModules/InternalServices/API/ContentWorkflowService/Approve',
-1,

GETDATE(),
-1,
GETDATE()
)

/* Add Discard notification action */
/* also

uses the existing Reject method */
INSERT INTO

dbo.CoreMessaging_NotificationTypeActions(
[NotificationTypeID],

[NameResourceKey],
[DescriptionResourceKey],
[ConfirmResourceKey],
[Order],

[APICall],
[CreatedByUserID],
[CreatedOnDate],
[LastModifiedByUserID],

[LastModifiedOnDate])
VALUES(
@NotificationStartWorkflowTypeId,
'Discard',

'Discard',
NULL,
1,

'DesktopModules/InternalServices/API/ContentWorkflowService/Reject',
-1,

GETDATE(),
-1,
GETDATE()
)
END

The above procedure has been tried to times on the installation, after reverting back to the running 7.3.4 each time and the upgrade is been tried with the very same message,

QA Test Plan

Status

Assignee

Unassigned

Reporter

InteliBrain

Story Size

Unknown

Severity

Major

Triage

Triaged

Includes Code Fix

No

Injected

Injected

Components

Affects versions

7.4.0

Priority

Blocker