2

I need to create two new columns in a standard list, one is called "AB12" and the other one "AB13". But when I create them, the internal names of them turns into "_x0041_B12" and "_x0041_B13". It seems the first letter converts into some sort of ASCI hexadecimal value.

I tried some other column names just for testing:

  • Column "A234567890" has the internal name "A234567890" (no issue here)
  • Column "1234567890" has the internal name "_x0031_234567890" (same issue)
  • Column "ABC12" has the internal name "_x0041_BC12" (same issue)
  • Column "ABCD12" has the internal name "ABCD12" (no issue here)

I really need the two column internal names to be called "AB12" and "AB13", anyone knows what the issue is?

5
  • Try creating list column using powershell. Provide internal name and display name both
    – Deepmala
    Commented Jan 25, 2018 at 10:29
  • We tried creating the columns via PowerShell, we tried via schema.xml and also tried via the simple web interface, they all result in the same issues with internal names. The display names are always correct(the same). We tried the same tests on 3 different SharePoint 2016 servers, and one SharePoint 2010 server, all of them had the same issue with internal names(display names were still unaffected)
    – Prince
    Commented Jan 25, 2018 at 11:01
  • Creating the column via powershell: // Creating the field $NameFldSchema="<Field Type='Text' DisplayName='AB12' Required='False' MaxLength='255' StaticName='AB12' Name='AB12' />" $List.Fields.AddFieldAsXml($NameFldSchema, $True,[Microsoft.SharePoint.SPAddFieldOptions]::AddFieldToDefaultView) _x0041_B12
    – Prince
    Commented Jan 25, 2018 at 11:18
  • Getting the column information via powershell: // Getting the field information $fields["AB12"].SchemaXml <Field Type="Text" DisplayName="AB12" Required="False" MaxLength="255" StaticName="AB12" Name="_x0041_B12" ID="{bdfa6b6e-65c3-488a-b7e5-89f152fe9541}" SourceID="{4d503a5 8-e2c7-49a8-8e3e-5af955267322}" ColName="nvarchar2" RowOrdinal="0" Version="1"/>
    – Prince
    Commented Jan 25, 2018 at 11:19
  • Using powershell, try using double quotes around DisplayName, StaticName and Name. Also, what happens if you use a fake A like this?
    – Sergio
    Commented Jan 25, 2018 at 20:28

1 Answer 1

0

I have reproduced your issue. Even I add a field and specify the internal name for this field using PowerShell, the internal name still will become to "_x0041_B12". As the internal name is unique non-changeable string that identifies a field in the list, we cannot change the internal name. I suppose it is by design. SharePoint will convert the character to hexadecimal to ensure it can be resolved by the system.

1
  • This is quite strange as we are currently migrating a SharePoint 2010 application to 2016, and looking at the older already-deployed 2010 server, the "AB12" and "AB13" have the correct internal names. However when we edit a list in that same 2010 server and add the two columns we get the bug. Possibly there was a patch that was released to all SharePoint servers(2010, 2013 and 2016) which broke the "internal name encoder/generator"`?
    – Prince
    Commented Jan 26, 2018 at 11:27

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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