SharePoint 2013 developers are gonna have a hard time while dealing with content types. In previous version of SharePoint, SharePoint allowed existence of content type fields with similar internal names. Hence we were able to deploy the same field multiple times belonging to different content types.
In this new version of SharePoint 2013, it throws an error while deployment stating that ‘A Duplicate field <field_name> already exists’. Thus, in SharePoint 2013, Content Types being site-scoped features do not allow existence of fields with similar internal names.
That being said, we can always take some measures and precautions while creating and deploying our custom content types. I have jot down some steps to do the same as under -
- Make sure the sequence in which various content types are being deployed by looking at its manifest file.
- Include all the field definitions in the first content type and then re-use those field GUIDs in the subsequent content types. This approach would make it easy in terms of implementation
- Refer fields which are available out-of-the-box by SP 2013 (please note that these fields are different from what SP 2010 offered).
This would surely eliminate the duplicate field issue. Following are some of the content types and their respective fields available OOTB in a SharePoint 2013 blank site. The list is very long, hence i have mentioned only a few. You can get the entire list by running the following PowerShell script -
$site = Get-SPSite "http://<your_site_url_goes_here>/"
$web = $site.OpenWeb()
foreach($type in $web.ContentTypes)
{
"----------------------------------------------------------------------------------"
$type.Name
"----------------------------------------------------------------------------------"
foreach($field in $type.Fields)
{
$field | Select InternalName, Type
}
}
Here's an excerpt from the list -
------------------------------------------------------------------------------------
System
------------------------------------------------------------------------------------
ContentType Computed
------------------------------------------------------------------------------------
Common Indicator Columns
------------------------------------------------------------------------------------
ContentType Computed
KpiDescription Note
KpiComments Note
Value Number
Goal Number
Warning Number
FormattedValue Text
FormattedGoal Text
FormattedWarning Text
DetailLink URL
LowerValuesAreBetter Boolean
UpdateError Note
LastUpdated DateTime
------------------------------------------------------------------------------------
Fixed Value based Status Indicator
------------------------------------------------------------------------------------
ContentType Computed
KpiDescription Note
KpiComments Note
Value Number
Goal Number
Warning Number
FormattedValue Text
FormattedGoal Text
FormattedWarning Text
DetailLink URL
LowerValuesAreBetter Boolean
UpdateError Note
LastUpdated DateTime
------------------------------------------------------------------------------------
SharePoint List based Status Indicator
------------------------------------------------------------------------------------
ContentType Computed
KpiDescription Note
KpiComments Note
Value Number
Goal Number
Warning Number
FormattedValue Text
FormattedGoal Text
FormattedWarning Text
DetailLink URL
LowerValuesAreBetter Boolean
UpdateError Note
LastUpdated DateTime
DataSource URL
ViewGuid Text
ValueExpression Note
PercentExpression Boolean
AutoUpdate Boolean
------------------------------------------------------------------------------------
Excel based Status Indicator
------------------------------------------------------------------------------------
ContentType Computed
KpiDescription Note
KpiComments Note
Value Number
Goal Number
Warning Number
FormattedValue Text
FormattedGoal Text
FormattedWarning Text
DetailLink URL
LowerValuesAreBetter Boolean
UpdateError Note
LastUpdated DateTime
DataSource URL
ValueSheet Text
ValueCell Text
GoalSheet Text
GoalCell Text
WarningSheet Text
WarningCell Text
GoalFromWorkBook Boolean
WarningFromWorkBook Boolean
AutoUpdate Boolean
------------------------------------------------------------------------------------
SQL Server Analysis Services based Status Indicator
------------------------------------------------------------------------------------
ContentType Computed
KpiDescription Note
KpiComments Note
Value Number
Goal Number
Warning Number
FormattedValue Text
FormattedGoal Text
FormattedWarning Text
DetailLink URL
LowerValuesAreBetter Boolean
UpdateError Note
LastUpdated DateTime
DataSource URL
Trend Number
KpiStatus Number
DisplayFolder Text
KPI Text
IncludeHierarchy Boolean
AutoUpdate Boolean
------------------------------------------------------------------------------------
Item
------------------------------------------------------------------------------------
ContentType Computed
Title Text
------------------------------------------------------------------------------------
Circulation
------------------------------------------------------------------------------------
ContentType Computed
Title Text
Body Note
DueDate DateTime
Confidential Boolean
AllowEditing Boolean
V4SendTo User
Confirmations Text
V3Comments Note
WhatsNew Boolean
------------------------------------------------------------------------------------
New Word
------------------------------------------------------------------------------------
ContentType Computed
Title Text
IMEDisplay Text
IMEComment1 Text
IMEComment2 Text
IMEComment3 Text
IMEUrl URL
IMEPos Choice
------------------------------------------------------------------------------------
Category
------------------------------------------------------------------------------------
ContentType Computed
Title Text
CategoryDescription Text
CategoryImage URL
TopicCount Integer
ReplyCount Integer
LastPostBy User
LastPostDate DateTime
------------------------------------------------------------------------------------
Site Membership
------------------------------------------------------------------------------------
ContentType Computed
Title Text
Member User
MemberStatus Choice
MemberStatusInt Integer
------------------------------------------------------------------------------------
Community Member
------------------------------------------------------------------------------------
ContentType Computed
Member User
MemberStatus Choice
MemberStatusInt Integer
Title Text
LastActivity DateTime
NumberOfBestResponses Number
NumberOfDiscussions Number
NumberOfReplies Number
NumberOfRepliesToReachNextLevel Number
ReputationScore Number
HideReputation Boolean
------------------------------------------------------------------------------------
WorkflowServiceDefinition
------------------------------------------------------------------------------------
ContentType Computed
Title Text
WSGUID Guid
WSPublishState Integer
WSPublishError Note
WSDisplayName Text
WSDescription Text
FormData Note
------------------------------------------------------------------------------------
InviteUser
------------------------------------------------------------------------------------
ContentType Computed
Title Text
EmailTemplate Note
LoggedUser Text
SentAt Text
InviteUser_Recipients Note
CurrentSiteCollection Text
------------------------------------------------------------------------------------
Health Analyzer Rule Definition
------------------------------------------------------------------------------------
ContentType Computed
Title Text
HealthRuleScope Choice
HealthRuleService Text
HealthRuleType Text
HealthReportCategory Choice
HealthRuleSchedule Choice
HealthRuleCheckEnabled Boolean
HealthRuleAutoRepairEnabled Boolean
HealthRuleVersion Text