Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I just created a couple of site columns and content types that reference them through VS2010. I updated one of the fields and then tried to redeploy, but after retracting, deploy failed because the site columns previously created were still there. I tried to delete them manually from the UI, and got an alert box with this message:

Site columns which are included in content types cannot be deleted. Remove all references to this site column prior to deleting it.

I dug around in SharePoint Manager and didn't find any references, so I used powershell to enumerate all the content types and lists looking for references to my site columns and found nothing.

I tried to delete using PowerShell like this:

$web.Fields.Delete("StartTime")

which resulted in this error:

Exception calling "Delete" with "1" argument(s): "Site columns which are included in content types or on lists cannot be deleted. Please remove all instances of this site column prior to deleting it." At line:1 char:19 + $web.Fields.Delete <<<< ("StartTime") + CategoryInfo : NotSpecified: (:) [], MethodInvocationException + FullyQualifiedErrorId : DotNetMethodException

Finally, a simple inspection of the columns in PowerShell shows the following:

Title Id CanBeDeleted ParentList Sealed ListsFieldUsedIn
----- -- ------------ ---------- ------ ----------------
Start Time OBE 6fa0d85b-9af1-408b-835f-d4c66536... True False {}
Time Tracker Tags 92bc866b-0415-45f0-b431-d4df69c4... True False {}

I'm experienced with MOSS 2007 and new to SP2010, but I've never seen this happen before. Anyone have any hints?

share|improve this question
add comment

3 Answers

up vote 1 down vote accepted

So you did deployed your column via a Feature right? This also means that you won't be able to remove it manually.

You need to make sure you emptied Recycle Bin (both sub-sites and site collection) to attempt removing used references. Than try to remove again your feature.

ON YOUR OWN RISK (i did successfully fixed some CTs this way...but you never know):

use this to locate information about your column http://blog.sharepointsite.co.uk/2011/05/corrupt-site-column-cannot-be-deleted.html

and then use this http://blog.tylerholmes.com/2008/02/deleting-content-types-in-sharepoint.html to actually delete the offending CT with its columns.

share|improve this answer
add comment

If you go to "Site Actions > Manage content and structure" and find the offending item - there's a button to show item dependencies. This way you can weed out what is still using the field and remove it before removing the field altogether.

share|improve this answer
add comment

Isn't "StartTime" an built-in column used by the Tasks content types?

share|improve this answer
    
there is an OOTB column called "Start Date". –  Ben Collins Feb 21 '11 at 16:25
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.