columns dereferencing in SharePoint's calculated column

后端 未结 2 2067
南旧
南旧 2021-01-28 19:04

I want to use the simple formula:

=\"FIX_\" & [ID]

The issue with this formula occurs when I confirm the calculated function, the formula a

2条回答
  •  情歌与酒
    2021-01-28 19:36

    The [ ] notation has got nothing to do with it.. [ ] are only required if fieldnames contain spaces.. As you experienced SharePoint will strip those [ ] on save.

    why ID is not listed as a usable Field for Formulas

    You can not use the ID in a calculated column because on first Item creation the Calculated Column Formula is processed before the item is written to the database and gets its ID.

    Thus ID is 0 for newly created items

    When an Item is changed/updated the ID is correctly populated and used with the correct value in Formulas.

    Work-around is to create a Workflow (which runs after Item creation) that gets the ID and writes it to another field, and use that in your Formula

    or have the workflow changes something else in any field so an item update is forced; reading the Title and write it back in the same field will do.

提交回复
热议问题