This and the following step is often missed out in other articles but cause problems if I try to create custom list definitions that include the managed metadata column. The specific error message I get is:
Error – Failed to get value of the “{0}” column from the “Managed Metadata” field type control. See details in log. Exception message: Invalid field name. {00000000-0000-0000-0000-000000000000}:
How can I resolve this problem? Have any idea then deliver it to me. Thanks in advance.
I recently came across an issue on a client site and on the Project Server forums with creating a new Portfolio Analysis, clicking the new button threw the error below. I am looking for an expert’s advice to fix this issue. Any idea would be greatly appreciated. Thanks in advance.
Error:
Error.
Failed to get value of the “Regional Office” column from the “Managed Metdata” field type contol. See details in log.
Exception message: Invalid field name. {00000000-0000-0000-0000-00000000}
http://teams/sites/another/sites/another/RegionalDocumentLibrary.
Troubleshoot issue with Microsoft SharePoint Foundation.
Correlation ID: f674af4c-4556-4187-a225-95d8d3657099
Date and Time:3/2/2011 12:47:43 AM
Exception message Invalid field name
If you create a list definition that uses this site column you get the error:
Failed to get value of the “{0}” column from the “Managed Metadata” field type control. See details in log. Exception message: Invalid field name. {00000000-0000-0000-0000-000000000000}.
The managed metadata column does not appear in the search refinement panel as per columns created through the UI. If the managed metadata features are not activated in the site the field will not work (and no obvious errors will be displayed).We found the first problem was due to a missing note field when creating a list definition that used the site column.
The second problem was due to the missing TaxCatchAll and TaxCatchAllLabel columns and missing event receivers on the list definition. The last issue can be easily avoided by adding a feature dependency to ensure the required feature is activated before we deploy our custom site column. With this information we can use the following steps to deploy managed metadata fields that avoid these issues. I’ve also created an example project that I’ve included at the end of the article if you want to see this working for yourself.
Create a managed metadata field
-
Provision a managed metadata field using type TaxonomyFieldType (or TaxonomyFieldTypeMulti to allow multiple values)
-
Configure the managed metadata column to reference an existing term set
-
Provision a hidden field of type Note
-
Configure the managed metadata column to use the hidden Note field
-
Ensure that the TaxonomyFieldAdded feature is activated on the site collection
Create a list definition that uses a managed metadata field
-
Create a content type that uses the managed metadata fields and the TaxCatchAll columns
-
Create a list definition that uses the content type and includes all metadata and TaxCatchAll columns
-
Attach the TaxonomyItemSynchronousAddedEventReceiver and TaxonomyItemUpdatingEventReceiver event receivers to the list definition
-
Create a list instance to provision instances of the list definition
Exception message Invalid field name
It seems that somehow your Note field gets deleted. (Can’t guess exactly why/how)
Now if you try this library to work again, delete this column and then try adding this from Site Column again but “You will lose the data for all items for that column”
You can use a little bit of power shell to save your data and make your library work again.
-
You need to write a power shell to copy the data from this broken Metadata field to a text field.
-
Then delete this broken Metadata field.
-
From the Site column add the new metadata field.
-
In this field fill the value from the respective Text field for each item.
Hope this will solve your problem.