Forum Discussion
MST97
Oct 09, 2019Copper Contributor
Generate a unique number like ID in A SharePoint list.
Hello, I have created a SP List. From what I see every item has a unique number (ID). I found out that there is impossible to reset this ID number. I would like to add a column which generate a num...
- Oct 09, 2019may I ask why you would reset it if it needs to be unique? Technically speaking if you need to just go quarter to quarter with the number, type of thing, you could always just use a calculated column and user [ID] for first quarter, then if you have a hard reset of items, you can then go set that column to [ID] minus whatever your ID currently is at.
It's not pretty, but depending on your use case on how that flows it could work assuming you no longer care about the numbers once you do a reset. Otherwise flow would be your solution and you could take a similar logic without needing to maintain another list, you can just update the flow to subtract however many you want to reset back too off of the ID column.
The difference with option 1 vs. flow, is flow would set the individual list item number, using calculated method reevaluates the number for all the existing items once you change it.
Oct 09, 2019
may I ask why you would reset it if it needs to be unique? Technically speaking if you need to just go quarter to quarter with the number, type of thing, you could always just use a calculated column and user [ID] for first quarter, then if you have a hard reset of items, you can then go set that column to [ID] minus whatever your ID currently is at.
It's not pretty, but depending on your use case on how that flows it could work assuming you no longer care about the numbers once you do a reset. Otherwise flow would be your solution and you could take a similar logic without needing to maintain another list, you can just update the flow to subtract however many you want to reset back too off of the ID column.
The difference with option 1 vs. flow, is flow would set the individual list item number, using calculated method reevaluates the number for all the existing items once you change it.
It's not pretty, but depending on your use case on how that flows it could work assuming you no longer care about the numbers once you do a reset. Otherwise flow would be your solution and you could take a similar logic without needing to maintain another list, you can just update the flow to subtract however many you want to reset back too off of the ID column.
The difference with option 1 vs. flow, is flow would set the individual list item number, using calculated method reevaluates the number for all the existing items once you change it.
MST97
Oct 10, 2019Copper Contributor
ChrisWebbTechthank you for reply. I achieve what I wanted. I choose to use your first advice. I added a calculated column and I done the difference between ID and a number. I use this list to store some data and using flow I create a word document from a template with them. The name of the document I want to start from 1. My ID list is 78 right now and I couldn't use it... that's way I wanted to reset the ID column/create a new column with a unique number.
Thank youuuu very much!