Hi Scott,
The 3.0.13 site was on GoDaddy's shared plan. So, I purchased/installed XPIdea's Backup/Restore module and backed up the site and db. No other modules. I installed a fresh copy of 3.0.13 on my new dedicated server, and then restored the site/db using the same product. Then I downloaded the 3.3.5 Upgrade package and performed the upgrade exactly as stated in the DNN installation manual. Following is the text from the upgrade log and following that are the actual error logs:
Upgrading DotNetNuke
Current Assembly Version: 03.03.05
Current Database Version: 03.00.13
00:00:00.046 - Executing Script: C:\Inetpub\CVSTI\Providers\DataProviders\SqlDataProvider\Upgrade.SqlDataProvider
Upgrade Status Report
00:00:00.296 - Upgrading to Version: 3.1.0 Error! (seeC:\Inetpub\CVSTI\Providers\DataProviders\SqlDataProvider\03.01.00.log for more information)
00:00:02.484 - Upgrading to Version: 3.1.1 Success
00:00:05.125 - Upgrading to Version: 3.2.0 Success
00:00:05.531 - Upgrading to Version: 3.2.1 Error! (seeC:\Inetpub\CVSTI\Providers\DataProviders\SqlDataProvider\03.02.01.log for more information)
00:00:05.781 - Upgrading to Version: 3.2.2 Success
00:00:05.781 - Upgrading to Version: 3.2.3 Error! (seeC:\Inetpub\CVSTI\Providers\DataProviders\SqlDataProvider\03.02.03.log for more information)
00:00:09.140 - Upgrading to Version: 3.2.4 Success
00:00:09.187 - Upgrading to Version: 3.2.5 Success
00:00:09.234 - Upgrading to Version: 3.2.6 Success
00:00:09.281 - Upgrading to Version: 3.2.7 Success
00:00:09.281 - Upgrading to Version: 3.3.0 Success
00:00:09.796 - Upgrading to Version: 3.3.1 Error! (seeC:\Inetpub\CVSTI\Providers\DataProviders\SqlDataProvider\03.03.01.log for more information)
00:00:09.890 - Upgrading to Version: 3.3.2 Success
00:00:10.046 - Upgrading to Version: 3.3.3 Error! (seeC:\Inetpub\CVSTI\Providers\DataProviders\SqlDataProvider\03.03.03.log for more information)
00:00:10.296 - Upgrading to Version: 3.3.4 Success
00:00:10.296 - Upgrading to Version: 3.3.5 Success
00:00:10.703 - Performing General Upgrades
Upgrade Complete
---
3.1.0 Error Log
System.Data.SqlClient.SqlException: 'IX_dnn_DesktopModules' is not a constraint.
Could not drop constraint. See previous errors.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
ALTER TABLE dbo.dnn_DesktopModules
DROP CONSTRAINT IX_dnn_DesktopModules
---
3.2.1 Error Log
System.Data.SqlClient.SqlException: 'FK_dnn_SearchItemWord_dnn_SearchWord' is not a constraint.
Could not drop constraint. See previous errors.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
ALTER TABLE dbo.dnn_SearchItemWord
DROP CONSTRAINT FK_dnn_SearchItemWord_dnn_SearchWord
System.Data.SqlClient.SqlException: There are no primary or candidate keys in the referenced table 'dbo.dnn_SearchWord' that match the referencing column list in the foreign key 'FK_dnn_SearchItemWord_dnn_SearchWord'.
Could not create constraint. See previous errors.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
ALTER TABLE dbo.dnn_SearchItemWord WITH NOCHECK ADD CONSTRAINT
FK_dnn_SearchItemWord_dnn_SearchWord FOREIGN KEY (SearchWordsID) REFERENCES dbo.dnn_SearchWord(SearchWordsID) ON UPDATE CASCADE ON DELETE CASCADE
System.Data.SqlClient.SqlException: 'FK_dnn_SearchItemWordPosition_dnn_SearchItemWord' is not a constraint.
Could not drop constraint. See previous errors.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
ALTER TABLE dbo.dnn_SearchItemWordPosition
DROP CONSTRAINT FK_dnn_SearchItemWordPosition_dnn_SearchItemWord
System.Data.SqlClient.SqlException: There are no primary or candidate keys in the referenced table 'dbo.dnn_SearchItemWord' that match the referencing column list in the foreign key 'FK_dnn_SearchItemWordPosition_dnn_SearchItemWord'.
Could not create constraint. See previous errors.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
ALTER TABLE dbo.dnn_SearchItemWordPosition WITH NOCHECK ADD CONSTRAINT
FK_dnn_SearchItemWordPosition_dnn_SearchItemWord FOREIGN KEY (SearchItemWordID) REFERENCES dbo.dnn_SearchItemWord (SearchItemWordID) ON UPDATE CASCADE ON DELETE CASCADE
---
3.2.3 Error Log
System.Data.SqlClient.SqlException: There are no primary or candidate keys in the referenced table 'dbo.dnn_Portals' that match the referencing column list in the foreign key 'FK_dnn_RoleGroups_dnn_Portals'.
Could not create constraint. See previous errors.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
/************************************************************/
/***** SqlDataProvider *****/
/***** *****/
/***** *****/
/***** Note: To manually execute this script you must *****/
/***** perform a search and replace operation *****/
/***** for dbo. and dnn_ *****/
/***** *****/
/************************************************************/
/* Add RoleGroups Table */
/************************/
IF NOT EXISTS (select * from dbo.sysobjects where id = object_id(N'dbo.[dnn_RoleGroups]') and OBJECTPROPERTY(id, N'IsTable') = 1)
BEGIN
CREATE TABLE dbo.dnn_RoleGroups
(
[RoleGroupID] int IDENTITY(0,1) NOT NULL,
[PortalID] int NOT NULL,
[RoleGroupName] nvarchar(50) NOT NULL,
[Description] nvarchar(1000) NULL
)
ALTER TABLE dbo.dnn_RoleGroups
ADD CONSTRAINT [PK_dnn_RoleGroups] PRIMARY KEY NONCLUSTERED ([RoleGroupID])
ALTER TABLE dbo.dnn_RoleGroups
ADD CONSTRAINT [IX_dnn_RoleGroupName] UNIQUE NONCLUSTERED ([PortalID] ASC, [RoleGroupName] ASC)
ALTER TABLE dbo.dnn_RoleGroups WITH NOCHECK
ADD CONSTRAINT [FK_dnn_RoleGroups_dnn_Portals] FOREIGN KEY([PortalID]) REFERENCES dbo.[dnn_Portals] ([PortalID]) ON DELETE CASCADE
ALTER TABLE dbo.dnn_Roles
ADD RoleGroupID int NULL
ALTER TABLE dbo.dnn_Roles
ADD CONSTRAINT FK_dnn_Roles_dnn_RoleGroups FOREIGN KEY (RoleGroupID) REFERENCES dbo.dnn_RoleGroups (RoleGroupID)
END
System.Data.SqlClient.SqlException: Invalid column name 'RoleGroupId'.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
CREATE PROCEDURE dbo.[dnn_AddRole]
@PortalId int,
@RoleGroupId int,
@RoleName nvarchar(50),
@Description nvarchar(1000),
@ServiceFee money,
@BillingPeriod int,
@BillingFrequency char(1),
@TrialFee money,
@TrialPeriod int,
@TrialFrequency char(1),
@IsPublic bit,
@AutoAssignment bit,
@RSVPCode nvarchar(50),
@IconFile nvarchar(100)
AS
INSERT INTO dbo.dnn_Roles (
PortalId,
RoleGroupId,
RoleName,
Description,
ServiceFee,
BillingPeriod,
BillingFrequency,
TrialFee,
TrialPeriod,
TrialFrequency,
IsPublic,
AutoAssignment,
RSVPCode,
IconFile
)
VALUES (
@PortalId,
@RoleGroupId,
@RoleName,
@Description,
@ServiceFee,
@BillingPeriod,
@BillingFrequency,
@TrialFee,
@TrialPeriod,
@TrialFrequency,
@IsPublic,
@AutoAssignment,
@RSVPCode,
@IconFile
)
SELECT SCOPE_IDENTITY()
System.Data.SqlClient.SqlException: Invalid column name 'RoleGroupId'.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
CREATE PROCEDURE dbo.[dnn_GetPortalRoles]
@PortalId int
AS
SELECT R.RoleId,
R.PortalId,
R.RoleGroupId,
R.RoleName,
R.Description,
'ServiceFee' = case when convert(int,R.ServiceFee) <> 0 then R.ServiceFee else null end,
'BillingPeriod' = case when convert(int,R.ServiceFee) <> 0 then R.BillingPeriod else null end,
'BillingFrequency' = case when convert(int,R.ServiceFee) <> 0 then L1.Text else '' end,
'TrialFee' = case when R.TrialFrequency <> 'N' then R.TrialFee else null end,
'TrialPeriod' = case when R.TrialFrequency <> 'N' then R.TrialPeriod else null end,
'TrialFrequency' = case when R.TrialFrequency <> 'N' then L2.Text else '' end,
'IsPublic' = case when R.IsPublic = 1 then 'True' else 'False' end,
'AutoAssignment' = case when R.AutoAssignment = 1 then 'True' else 'False' end,
RSVPCode,
IconFile
FROM dbo.dnn_Roles R
LEFT OUTER JOIN dbo.dnn_Lists L1 on R.BillingFrequency = L1.Value
LEFT OUTER JOIN dbo.dnn_Lists L2 on R.TrialFrequency = L2.Value
WHERE PortalId = @PortalId
OR PortalId is null
ORDER BY R.RoleName
System.Data.SqlClient.SqlException: Invalid column name 'RoleGroupId'.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
CREATE PROCEDURE dbo.[dnn_GetRole]
@RoleId int,
@PortalId int
AS
SELECT RoleId,
PortalId,
RoleGroupId,
RoleName,
Description,
ServiceFee,
BillingPeriod,
BillingFrequency,
TrialFee,
TrialPeriod,
TrialFrequency,
IsPublic,
AutoAssignment,
RSVPCode,
IconFile
FROM dnn_Roles
WHERE RoleId = @RoleId
AND PortalId = @PortalId
System.Data.SqlClient.SqlException: Invalid column name 'RoleGroupId'.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
CREATE PROCEDURE dbo.[dnn_GetRoleByName]
@PortalId int,
@RoleName nvarchar(50)
AS
SELECT RoleId,
PortalId,
RoleGroupId,
RoleName,
Description,
ServiceFee,
BillingPeriod,
BillingFrequency,
TrialFee,
TrialPeriod,
TrialFrequency,
IsPublic,
AutoAssignment,
RSVPCode,
IconFile
FROM dnn_Roles
WHERE PortalId = @PortalId
AND RoleName = @RoleName
System.Data.SqlClient.SqlException: Invalid column name 'RoleGroupId'.
Invalid column name 'RoleGroupId'.
Invalid column name 'RoleGroupId'.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
CREATE PROCEDURE dbo.[dnn_GetRolesByGroup]
@RoleGroupId int,
@PortalId int
AS
SELECT R.RoleId,
R.PortalId,
R.RoleGroupId,
R.RoleName,
R.Description,
'ServiceFee' = case when convert(int,R.ServiceFee) <> 0 then R.ServiceFee else null end,
'BillingPeriod' = case when convert(int,R.ServiceFee) <> 0 then R.BillingPeriod else null end,
'BillingFrequency' = case when convert(int,R.ServiceFee) <> 0 then L1.Text else '' end,
'TrialFee' = case when R.TrialFrequency <> 'N' then R.TrialFee else null end,
'TrialPeriod' = case when R.TrialFrequency <> 'N' then R.TrialPeriod else null end,
'TrialFrequency' = case when R.TrialFrequency <> 'N' then L2.Text else '' end,
'IsPublic' = case when R.IsPublic = 1 then 'True' else 'False' end,
'AutoAssignment' = case when R.AutoAssignment = 1 then 'True' else 'False' end,
R.RSVPCode,
R.IconFile
FROM dbo.dnn_Roles R
LEFT OUTER JOIN dbo.dnn_Lists L1 on R.BillingFrequency = L1.Value
LEFT OUTER JOIN dbo.dnn_Lists L2 on R.TrialFrequency = L2.Value
WHERE (RoleGroupId = @RoleGroupId OR (RoleGroupId IS NULL AND @RoleGroupId IS NULL))
AND PortalId = @PortalId
ORDER BY R.RoleName
System.Data.SqlClient.SqlException: Invalid column name 'RoleGroupId'.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
CREATE PROCEDURE dbo.[dnn_UpdateRole]
@RoleId int,
@RoleGroupId int,
@Description nvarchar(1000),
@ServiceFee money,
@BillingPeriod int,
@BillingFrequency char(1),
@TrialFee money,
@TrialPeriod int,
@TrialFrequency char(1),
@IsPublic bit,
@AutoAssignment bit,
@RSVPCode nvarchar(50),
@IconFile nvarchar(100)
AS
UPDATE dbo.dnn_Roles
SET RoleGroupId = @RoleGroupId,
Description = @Description,
ServiceFee = @ServiceFee,
BillingPeriod = @BillingPeriod,
BillingFrequency = @BillingFrequency,
TrialFee = @TrialFee,
TrialPeriod = @TrialPeriod,
TrialFrequency = @TrialFrequency,
IsPublic = @IsPublic,
AutoAssignment = @AutoAssignment,
RSVPCode = @RSVPCode,
IconFile = @IconFile
WHERE RoleId = @RoleId
System.Data.SqlClient.SqlException: There are no primary or candidate keys in the referenced table 'dbo.dnn_Users' that match the referencing column list in the foreign key 'FK_dnn_UserProfile_dnn_Users'.
Could not create constraint. See previous errors.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
/* Add UserProfile Table */
/*************************/
IF NOT EXISTS (select * from dbo.sysobjects where id = object_id(N'dbo.[dnn_UserProfile]') and OBJECTPROPERTY(id, N'IsTable') = 1)
BEGIN
CREATE TABLE dbo.dnn_UserProfile
(
[ProfileID] int IDENTITY(1,1) NOT NULL,
[UserID] int NOT NULL,
[PropertyDefinitionID] int NOT NULL,
[PropertyValue] nvarchar(3750) NULL,
[PropertyText] ntext NULL,
[Visibility] int NOT NULL DEFAULT 0,
[LastUpdatedDate] datetime NOT NULL
)
ALTER TABLE dbo.dnn_UserProfile
ADD CONSTRAINT [PK_dnn_UserProfile] PRIMARY KEY NONCLUSTERED ([ProfileID])
ALTER TABLE dbo.dnn_UserProfile WITH NOCHECK
ADD CONSTRAINT [FK_dnn_UserProfile_dnn_Users] FOREIGN KEY([UserID]) REFERENCES dbo.[dnn_Users] ([UserID]) ON DELETE CASCADE
ALTER TABLE dbo.dnn_UserProfile WITH NOCHECK
ADD CONSTRAINT [FK_dnn_UserProfile_dnn_ProfilePropertyDefinition] FOREIGN KEY([PropertyDefinitionID]) REFERENCES dbo.[dnn_ProfilePropertyDefinition] ([PropertyDefinitionID]) ON DELETE CASCADE
END
System.Data.SqlClient.SqlException: There are no primary or candidate keys in the referenced table 'dbo.dnn_Folders' that match the referencing column list in the foreign key 'FK_dnn_Files_dnn_Folders'.
Could not create constraint. See previous errors.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
ALTER TABLE dbo.dnn_Files ADD CONSTRAINT
FK_dnn_Files_dnn_Folders FOREIGN KEY
(
FolderID
) REFERENCES dbo.dnn_Folders
(
FolderID
)
---
3.3.1 Error Log
System.Data.SqlClient.SqlException: There are no primary or candidate keys in the referenced table 'dbo.dnn_Folders' that match the referencing column list in the foreign key 'FK_dnn_Files_dnn_Folders'.
Could not create constraint. See previous errors.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
/* This sets all cache root folders to protected */
/*************************************************/
UPDATE dnn_Folders
SET IsProtected = 1
WHERE
FolderPath = 'Cache/'
/* This tries to apply a foreign key on the files/folders tables */
/*****************************************************************/
IF NOT EXISTS ( SELECT * FROM sysobjects WHERE id = object_id(N'FK_dnn_Files_dnn_Folders') AND OBJECTPROPERTY(id, N'IsForeignKey') = 1)
BEGIN
ALTER TABLE dbo.dnn_Files ADD CONSTRAINT
FK_dnn_Files_dnn_Folders FOREIGN KEY
(
FolderID
) REFERENCES dbo.dnn_Folders
(
FolderID
)
END
---
3.3.3 Error Log
System.Data.SqlClient.SqlException: There are no primary or candidate keys in the referenced table 'dbo.dnn_Portals' that match the referencing column list in the foreign key 'FK_dnn_ProfilePropertyDefinition_dnn_Portals'.
Could not create constraint. See previous errors.
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL)
at DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions)
IF NOT EXISTS ( SELECT * FROM sysobjects WHERE id = object_id(N'FK_dnn_ProfilePropertyDefinition_dnn_Portals') AND OBJECTPROPERTY(id, N'IsForeignKey') = 1)
ALTER TABLE dbo.dnn_ProfilePropertyDefinition
ADD CONSTRAINT FK_dnn_ProfilePropertyDefinition_dnn_Portals FOREIGN KEY (PortalID) REFERENCES dbo.dnn_Portals (PortalID) ON DELETE CASCADE
---