Copied to clipboard

Flag this post as spam?

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


  • Dan 1285 posts 3917 karma points c-trib
    Oct 09, 2009 @ 14:32
    Dan
    0

    Deleted data type causes document type error

    Hi,

    Apologies for cross-posting this (http://our.umbraco.org/projects/repeatable-custom-content/repeatable-custom-content/4497-Error) but it's moved from a package-specific issue to a more general issue, and I'm panicking slightly that a simple mistake may have scuppered my entire installation and am hoping a more general exposure on the forum might yield some helpful info.

    Basically, I created a datatype using the repeatable custom content v2 package and applied it to my homepage document type.  There was a  bug so I removed the package and re-installed it, but I didn't delete the data type from the document type prior to uninstalling the package.  Now when I browse to the homepage document type I get the following error:

     

    Server Error in '/' Application.

    No node exists with id '1421'

    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.ArgumentException: No node exists with id '1421'

    Source Error:

    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.


    Stack Trace:

    [ArgumentException: No node exists with id '1421']
    umbraco.cms.businesslogic.CMSNode.setupNode() +459
    umbraco.cms.businesslogic.CMSNode..ctor(Int32 Id) +25
    umbraco.cms.businesslogic.datatype.DataTypeDefinition.GetDataTypeDefinition(Int32 id) +88
    umbraco.cms.businesslogic.propertytype.PropertyType.get_DataTypeDefinition() +9
    umbraco.controls.GenericProperties.GenericProperty.UpdateInterface() +176
    umbraco.controls.GenericProperties.GenericProperty.Page_Load(Object sender, EventArgs e) +24
    System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +14
    System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +35
    System.Web.UI.Control.OnLoad(EventArgs e) +99
    System.Web.UI.Control.LoadRecursive() +50
    System.Web.UI.Control.LoadRecursive() +141
    System.Web.UI.Control.LoadRecursive() +141
    System.Web.UI.Control.LoadRecursive() +141
    System.Web.UI.Control.LoadRecursive() +141
    System.Web.UI.Control.LoadRecursive() +141
    System.Web.UI.Control.LoadRecursive() +141
    System.Web.UI.Control.LoadRecursive() +141
    System.Web.UI.Control.LoadRecursive() +141
    System.Web.UI.Control.LoadRecursive() +141
    System.Web.UI.Control.LoadRecursive() +141
    System.Web.UI.Control.LoadRecursive() +141
    System.Web.UI.Control.LoadRecursive() +141
    System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627

     

    I assume this is because there is still an association between the document type and the (now deleted) datatype.  Question is, how can I resolve this?  Can I remove the association directly in the database?  Loads of content pages on the site use this document type, so I can't delete it.  I'm starting to sweat a little thinking that this might be terminal!

    Thanks for any help with this...

  • Dan 1285 posts 3917 karma points c-trib
    Oct 09, 2009 @ 17:12
    Dan
    0

    Okay, I've taken a back-up in case things get even worse.  I'm now trawling the database to find anything with a nodeId of 1421 then renumbering it.  Question is, presumably the database content is cached somewhere along the line, so how do I check the effectiveness of each thing I try?  I might be doing something right, but the old broken data is still cached.

  • Dan 1285 posts 3917 karma points c-trib
    Oct 09, 2009 @ 17:24
    Dan
    0

    I think I've done it!  There was a record in cmsPropertyType which was referencing the offending deleted dataTypeId.  Sweating like an ill-informed bomb-disposal trainee, I removed that line from the database, renamed the web.config file, then named it back again (which seems to have cleared the cache) logged back into umbraco and... bingo!

    I'm hoping this doesn't have any further repercussions, but let this be a warning to any newbies on here: NEVER DELETE A DATA TYPE WITHOUT FIRST REMOVING ALL TRACES OF THAT DATA TYPE FROM YOUR DOCUMENT TYPES!

    Fingers crossed that this doesn't rear it's ugly head again.

Please Sign in or register to post replies

Write your reply to:

Draft