Hi,
For the below example data:
521358 abc
521358 abc
521358 abc
524536 ddd
564325 ddd
I want insert row numbers as
1 521358 abc
521358 abc
521358 abc
2 524536 ddd
3 564325 ddd
564325 ddd
Please look in an help me![]()
I kinda just made it up. But assuming all your data are in column B starting row 1
in A1 enter =COUNTIF($A$1:A1,A1)
in A2 enter =IF(COUNTIF($A$1:A2,A2)<>1,"",COUNT($B$1:B1)+1)
To thank someone who has helped you, click on the star icon below their name.
I hate reading
Portfolio
I need a job.I am young and incompetent
While applying this formula, it is not assigning number continuously, like
40 511167842
511167842
42 511178251
Instead of assigning 41 next to 40, it is calculating blank row and assigning next as 42.
My data starts from row# B2...
If your numbers start in B2, put this formula in A2, then copy down:
=IF(COUNTIF($B$1:$B2,$B2)=1, MAX($A$1:$A1)+1, "")
_________________
Microsoft MVP 2010 - Excel
Visit: Jerry Beaucaire's Excel Files & Macros
If you've been given good help, use theicon below to give reputation feedback, it is appreciated.
Always put your code between code tags. [CODE] your code here [/CODE]
“None of us is as good as all of us” - Ray Kroc
“Actually, I *am* a rocket scientist.” - JB (little ones count!)
Great guys, it works... thanks for your support![]()
If that takes care of your need, please click EDIT in your original post, click GO ADVANCED and set the PREFIX box to SOLVED.
_________________
Microsoft MVP 2010 - Excel
Visit: Jerry Beaucaire's Excel Files & Macros
If you've been given good help, use theicon below to give reputation feedback, it is appreciated.
Always put your code between code tags. [CODE] your code here [/CODE]
“None of us is as good as all of us” - Ray Kroc
“Actually, I *am* a rocket scientist.” - JB (little ones count!)
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks