HomeHomeDevelopment and...Development and...Building ExtensionsBuilding ExtensionsSkinsSkinsLegacy skins/containers upgraded with same package nameLegacy skins/containers upgraded with same package name
Previous
 
Next
New Post
6/21/2010 7:37 AM
 
I've just taken the plunge and upgraded from 4.9.5 to 5.4.2. Everything is going OK so far, discovering what's new and changed in DNN 5, until now.

Before the upgrade I used to create my own skins in what I consider to be the normal way, skin files in (for example) Portals/_default/Skins/MySkin and container files in Portals/_default/Containers/MySkin. 

After the upgrade, when I try to update any of my skins details (Host > Extensions > Edit (MySkin) > Update Extension) it fails with a SQLException "Cannot insert duplicate key row in object 'dbo.Packages' with unique index 'IX_Packages'.".

Looking at the dbo.Packages table and the dbo.UpdatePackage stored procedure I can see why. Both the skins and containers for MySkin have a package name of 'MySkin' but with different PackageTypes (Skin and Container respectively). The dbo.UpdatePackage stored procedure uses the package name as the key in the where clause, so it updates two rows, creating the duplicate key violation. 

I've created a temporary fix for myself by adding "[PackageType]= @PackageType" to the where clause.

Has anyone else come across this or do I have a problem with my upgrade?

Cheers,
Rhys


www.rmjcs.com - Mostly SQL Server Stuff
 
New Post
6/21/2010 8:29 AM
Accepted Answer 
This is a known limitation (AFAIR I logged this issue > 1 year ago). Feel free to log it at support.dotnetnuke.com again.

Cheers from Germany,
Sebastian Leupold (DotNetNuke MVP)

dnnWerk - The DotNetNuke Experts   German Spoken DotNetNuke User Group   European Network of DotNetNuke Professionals

 
New Post
6/21/2010 12:09 PM
 
Thanks for the quick response.

I'll do a little more work around the problem then log it as an issue.

Rhys

www.rmjcs.com - Mostly SQL Server Stuff
 
New Post
8/12/2010 12:10 AM
 
I'm having the same problem with DNN v 5.4.4.  Anyone have a link to a work-around?  I'm gathering I have to hack a stored procedure.  Any links?
 
New Post
8/12/2010 1:20 AM
 
Rhys wrote:
. The dbo.UpdatePackage stored procedure uses the package name as the key in the where clause, so it updates two rows, creating the duplicate key violation. 

I've created a temporary fix for myself by adding "[PackageType]= @PackageType" to the where clause.


 
Thanks, Rhys!  That mod to the UpdatePackage() stored procedure fixed the problem nicely.

WHERE [Name] = @Name AND [PackageType]= @PackageType

-- Christo

 
Previous
 
Next
HomeHomeDevelopment and...Development and...Building ExtensionsBuilding ExtensionsSkinsSkinsLegacy skins/containers upgraded with same package nameLegacy skins/containers upgraded with same package name


Forum Policy

These Discussion Forums are dedicated to the discussion of the DotNetNuke Web Application Framework.

For the benefit of the community and to protect the integrity of the project, 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 DotNetNuke.
2. Discussion or promotion of DotNetNuke product releases under a different brand name are strictly prohibited.
3. No Flaming or Trolling.
4. No Profanity, Racism, or Prejudice.
5. Site Moderators have the final word on approving/removing a thread or post or comment.
6. English language posting only, please.

Attend A Webinar
Start  Professional Edition Trial
Have Someone Contact Me

Like Us on Facebook Join our Network on LinkedIn Follow DNN Corporate on Twitter Follow DNN on Twitter

Advertisers

Sponsors

DotNetNuke Corporation

DotNetNuke (DNN) provides a suite of solutions that make designing, building and managing feature-rich sites and communities fast, easy and cost-effective. The DotNetNuke Platform CMS is the foundation for more than one million websites worldwide. DNN Social, our newest solution, enables businesses to create immersive, interactive communities. Thousands of organizations like True Value Hardware, Bose, Cornell University, Glacier Water, Dannon, Delphi, USAA, NASCAR, Northern Health and the City of Denver have leveraged DNN to deploy highly engaging business- critical websites. Our rapid growth in product sales and deployments resulted in DotNetNuke Corp. being named one of the fastest growing private companies in America by Inc. Magazine in 2011 and 2012.