Search code examples
excelvbaexcel-formulaexcel-2007vba7

Need to add UID for the data set in the excel sheet


I have a dataset and that have the values in B and C columns. I need to add the UID for every instances of data present in the B column. Example.

The column A should give me the UID for data set based on the data present in the column B.

[1]: https://i.sstatic.net/WvOke.png

I have tried many formulas but not seem to be relevant for what i am looking for.


Solution

  • Try below formula. Put the formula in A2 cell then drag and down.

    ="TT" & COUNTA($B$2:$B2)
    

    enter image description here