Products

Solutions

Resources

Partners

Community

About

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsMediaMediaInstall Error Media 04.01.00 on DNN 6 (06.01.02)Install Error Media 04.01.00 on DNN 6 (06.01.02)
Previous
 
Next
New Post
1/15/2012 9:31 PM
 

Hi all!

My upgrade from Media 04.00.00 to Media 04.01.00 errors  out as below:
--------------------------------------------------------------------------------------------------
Start jobb Starter Installering 

Info Starter Installering - DNN_Media 

Info Starter Installering - Script 

Info Start Sql-kjøringen 

Info Opprettet  

Info Utfører04.01.00.SqlDataProvider 

Info Start Sql-kjøringen: 04.01.00.SqlDataProvider filen 

Feil Sql-kjøringen årsaket følgende unntak: System.Data.SqlClient.SqlException: The ALTER TABLE statement conflicted with the FOREIGN KEY constraint "FK_dnn_Media_LastUpdatedBy". The conflict occurred in database "SwcWeb", table "dbo.dnn_Users", column 'UserID'. ved System.Data.SqlClient.SqlConnection. (SqlException exception, Boolean breakConnection) ved System.Data.SqlClient.SqlInternalConnection. (SqlException exception, Boolean breakConnection) ved System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) ved System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj) ved System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async) ved System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe) ved System.Data.SqlClient.SqlCommand.ExecuteNonQuery() ved DotNetNuke.Data.SqlDataProvider.ExecuteADOScript(String SQL) ved DotNetNuke.Data.SqlDataProvider.ExecuteScript(String Script, Boolean UseTransactions) IF NOT EXISTS (SELECT * FROM [dbo].[sysobjects] WHERE [id] = OBJECT_ID(N'FK_dnn_Media_LastUpdatedBy') AND OBJECTPROPERTY([id], N'IsConstraint') = 1) ALTER TABLE dbo.[dnn_Media] ADD CONSTRAINT [FK_dnn_Media_LastUpdatedBy] FOREIGN KEY ([LastUpdatedBy]) REFERENCES dbo.[dnn_Users] ([UserId]);  

Info Avslutt Sql-kjøringen: 04.01.00.SqlDataProvider filen 

Info Fullført Sql-kjøringen 

Feil Installasjonen feilet - Script 

Info Installasjonen feilet - DNN_Media 

Info Slettet midlertidig instalasjonsmappe 

Avslutt jobb Installasjonen  
--------------------------------------------------------------------------------------------

Please help ASAP
Thank you


Arnt O. Kvannefoss Software Consult AS Microsoft Certified Partner www.SwcWeb.net www.pamelding.net www.softwareconsult.no
 
New Post
1/16/2012 4:33 AM
Accepted Answer 
there seem to be a record in your Media table, where LastUpdatedBy points to a deleted user record. you may retrieve the item by executing the following statement in Host > SQL page:
SELECT * FROM media WHERE LastUpdatedBy NOT IN (SELECT UserId FROM Users)

You may correct the issue by executing (Giving 2 is the ID of your host user):
UPDATE media SET LastUpdatedBy = 2 WHERE LastUpdatedBy NOT IN (SELECT UserId FROM Users)

Cheers from Germany,
Sebastian Leupold

dnnWerk - The DotNetNuke Experts   German Spoken DotNetNuke User Group

Speed up your DNN Websites with TurboDNN
 
New Post
1/16/2012 11:34 AM
 

Sebastian,

Your are absolute correct, as usual. :)

Thank you!


Arnt O. Kvannefoss Software Consult AS Microsoft Certified Partner www.SwcWeb.net www.pamelding.net www.softwareconsult.no
 
New Post
1/17/2012 4:43 PM
 
Thanks, Sebastian! :)

Will Strohl

Upendo Ventures Upendo Ventures
DNN experts since 2003
Official provider of the Hotcakes Commerce Cloud and SLA support
 
New Post
8/6/2012 11:53 AM
 
I've had the same problem, and I noted a way to hot-fix the issue as well. See my comments on the Issue Tracker in the CodePlex site for this module: http://dnnmedia.codeplex.com/workitem/22139

My post(s) on the Issue Tracker include a recommended fix for the 04.01.00.SqlDataProvider script.

I've also have some thoughts on the whole idea of the Foreign Key constraint for the LastUpdatedBy column. In my view, this constraint should be dropped, and the default constraint for the LastUpdatedBy column should have a value of -1. My rationale is as follows:

Having the constraint between the tables can cause an adverse effect on the ability to delete a user who has been the last to update a media module. This "locks in" the user, causing administrative problems for the site (you can't permanently delete the user). Yet, at the same time, there is a desire to track who has last modified the module, and display meaningful information (name, etc.), and this information would be required.
 
Previous
 
Next
HomeHomeDNN Open Source...DNN Open Source...Module ForumsModule ForumsMediaMediaInstall Error Media 04.01.00 on DNN 6 (06.01.02)Install Error Media 04.01.00 on DNN 6 (06.01.02)


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out