SOLVED

Generate a unique number like ID in A SharePoint list.

%3CLINGO-SUB%20id%3D%22lingo-sub-901936%22%20slang%3D%22en-US%22%3EGenerate%20a%20unique%20number%20like%20ID%20in%20A%20SharePoint%20list.%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-901936%22%20slang%3D%22en-US%22%3E%3CP%3EHello%2C%3C%2FP%3E%3CP%3EI%20have%20created%20a%20SP%20List.%20From%20what%20I%20see%20every%20item%20has%20a%20unique%20number%20(ID).%20I%20found%20out%20that%20there%20is%20impossible%20to%20reset%20this%20ID%26nbsp%3B%20number.%20I%20would%20like%20to%20add%20a%20column%20which%20generate%20a%20number%20every%20time%20when%20a%20new%20item%20is%20added%2C%20similare%20with%20the%20ID.%26nbsp%3B%20Is%20this%20possible%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-901936%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3ELists%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3ESharePoint%20Online%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-902035%22%20slang%3D%22en-US%22%3ERe%3A%20Generate%20a%20unique%20number%20like%20ID%20in%20A%20SharePoint%20list.%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-902035%22%20slang%3D%22en-US%22%3ETotally%20possible%2C%20but%20you%20need%20to%20feed%20that%20column%20by%20means%20of%20a%20process%20that%20runs%20behind%20the%20scenes%20such%20as%20a%20Flow%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-902060%22%20slang%3D%22en-US%22%3ERe%3A%20Generate%20a%20unique%20number%20like%20ID%20in%20A%20SharePoint%20list.%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-902060%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F422853%22%20target%3D%22_blank%22%3E%40MST97%3C%2FA%3E%26nbsp%3B%20I%20agree%20with%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F60%22%20target%3D%22_blank%22%3E%40Juan%20Carlos%20Gonz%C3%A1lez%20Mart%C3%ADn%3C%2FA%3E%2C%20and%20one%20way%20you%20can%20do%20this%20is%20to%20have%20a%20separate%20list%20on%20your%20SharePoint%20site%20which%20just%20has%201%20item%20for%20the%20increment%20number.%20Then%20you'll%20need%20Flow%20to%20get%20that%20number%20and%20add%20it%20to%20the%20item%20then%20update%20it%20%2B1%20for%20the%20next%20item.%20If%20you%20need%20detailed%20steps%20for%20this%20come%20back%20to%26nbsp%3B%20us.%3C%2FP%3E%3CP%3ERob%3CBR%20%2F%3ELos%20Gallardos%3CBR%20%2F%3EMicrosoft%20Flow%20Community%20Super%20User%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-904307%22%20slang%3D%22en-US%22%3ERe%3A%20Generate%20a%20unique%20number%20like%20ID%20in%20A%20SharePoint%20list.%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-904307%22%20slang%3D%22en-US%22%3Emay%20I%20ask%20why%20you%20would%20reset%20it%20if%20it%20needs%20to%20be%20unique%3F%20Technically%20speaking%20if%20you%20need%20to%20just%20go%20quarter%20to%20quarter%20with%20the%20number%2C%20type%20of%20thing%2C%20you%20could%20always%20just%20use%20a%20calculated%20column%20and%20user%20%5BID%5D%20for%20first%20quarter%2C%20then%20if%20you%20have%20a%20hard%20reset%20of%20items%2C%20you%20can%20then%20go%20set%20that%20column%20to%20%5BID%5D%20minus%20whatever%20your%20ID%20currently%20is%20at.%20%3CBR%20%2F%3E%3CBR%20%2F%3EIt's%20not%20pretty%2C%20but%20depending%20on%20your%20use%20case%20on%20how%20that%20flows%20it%20could%20work%20assuming%20you%20no%20longer%20care%20about%20the%20numbers%20once%20you%20do%20a%20reset.%20Otherwise%20flow%20would%20be%20your%20solution%20and%20you%20could%20take%20a%20similar%20logic%20without%20needing%20to%20maintain%20another%20list%2C%20you%20can%20just%20update%20the%20flow%20to%20subtract%20however%20many%20you%20want%20to%20reset%20back%20too%20off%20of%20the%20ID%20column.%3CBR%20%2F%3E%3CBR%20%2F%3E%20The%20difference%20with%20option%201%20vs.%20flow%2C%20is%20flow%20would%20set%20the%20individual%20list%20item%20number%2C%20using%20calculated%20method%20reevaluates%20the%20number%20for%20all%20the%20existing%20items%20once%20you%20change%20it.%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-904601%22%20slang%3D%22en-US%22%3ERe%3A%20Generate%20a%20unique%20number%20like%20ID%20in%20A%20SharePoint%20list.%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-904601%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F869%22%20target%3D%22_blank%22%3E%40Chris%20Webb%3C%2FA%3Ethank%20you%20for%20reply.%26nbsp%3B%20I%20achieve%20what%20I%20wanted.%20I%20choose%20to%20use%20your%20first%20advice.%20I%20added%20a%20calculated%20column%20and%20I%20done%20the%20difference%20between%20ID%20and%20a%20number.%20I%20use%20this%20list%20to%20store%20some%20data%20and%20using%20flow%20I%20create%20a%20word%20document%20from%20a%20template%20with%20them.%20The%20name%20of%20the%20document%20I%20want%20to%20start%20from%201.%20My%20ID%20list%20is%2078%20right%20now%20and%20I%20couldn't%20use%20it...%20that's%20way%20I%20wanted%20to%20reset%20the%20ID%20column%2Fcreate%20a%20new%20column%20with%20a%20unique%20number.%3C%2FP%3E%3CP%3EThank%20youuuu%20very%20much!%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
New Contributor

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 number every time when a new item is added, similare with the ID.  Is this possible?

4 Replies
Totally possible, but you need to feed that column by means of a process that runs behind the scenes such as a Flow

@MST97  I agree with @Juan Carlos González Martín, and one way you can do this is to have a separate list on your SharePoint site which just has 1 item for the increment number. Then you'll need Flow to get that number and add it to the item then update it +1 for the next item. If you need detailed steps for this come back to  us.

Rob
Los Gallardos
Microsoft Flow Community Super User

Best Response confirmed by MST97 (New Contributor)
Solution
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.

@Chris Webbthank 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!