Deleting document types, content now inaccessible

1.5k views Asked by At

I am learning Umbraco (7) and deleted a test document type and template, without realising there was a content page using these (very surprised Umbraco lets you do this!)

I then couldn't access the content page to delete it (404 error). I created a new page, but that also had problems, almost certainly due to the database now having incorrect integrity, ie links now broken.

Two questions :

  1. is there any way to prevent deletions where there are still linked content elements?

  2. How would I fix this? Do I need to delete the orphaned content in the SQL backend db using SQL Management Studio? Or can something be done in the Umbraco front end eg scripts in macros?

Thanks

1

There are 1 answers

4
ProNotion On BEST ANSWER

Unfortunately deleting a document type does in fact remove all content using that document type, I am unaware of any way to recover this content other than to restore a backup.

It is a fundamental flaw I think that you are able to do this so easily and has been there for as long as I have been working with Umbraco (since v3!).

Have you tried rebuilding your XML Cache file to try and overcome the orphaned link problems?

http://YOURDOMAIN/Umbraco/dialogs/republish.aspx?xml=true and clicking "republish"

See this issue on the issue tracker:

U4-5187 Deleting doctype wipes out all content nodes based on it