1

I am trying to convert a term set column to either a text or number field. The list column was poorly designed and should have been a numeric or single line of text field in the first place. The column currently forces the user to select an item from the term store, "1" - "9999".

My first thought was to make a new column of the correct type and use the CSOM to copy the values over from the bad column to the new column. Then delete the bad column. However, this will set the "Modified" and "Modified by" columns to me. Since I'm not changing the data, just the way it's represented on the site, I would like to find a solution to this that doesn't affect the "Modified" and "Modified by" columns.

1 Answer 1

1

Your plan with adding new column, copying the values to it and deleting the old column sounds reasonable.

You can update the items without changing the modified/modified by fields by using the SystemUpdate() method.

4
  • That seems perfect. However that method isn't available to me. Maybe my Microsoft.SharePoint.Client.dll is out of date. I tried installing newer ones from nuget but it didn't work. What version has this method? (I'm using SharePoint server 2016) Jan 2, 2019 at 19:07
  • I am using the version for SP Online and it is available there. Since you are on the on-premise server, you could use the server side object model instead of csom to achieve the same. Jan 2, 2019 at 19:13
  • Unfortunately, I don't have access to develop on the company's SharePoint server Jan 2, 2019 at 19:43
  • As far as I can tell, the SystemUpdate method has been recently added and is only available in the SP Online version of the CSOM. So it looks like you're out of luck there. The alternative option would be to write some ssom powershell/c# code and ask someone with the appropriate permissions to run it on the server. Jan 2, 2019 at 20:00

Your Answer

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

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