# Give names an order rank

#### Beachson

##### Active Member

I start with a column of names (Column A) that are sorted in a particular way and I would like to get a formula that starts with the number 1 for the first name and increases by 1 everytime a name changes down the column. Essentially it would look like this ...

(A) (B)

Ben 1
Ben 1
Ben 1
Fred 2
Fred 2
Ben 3
Ben 3
Jim 4

Any help is appreciated! Thanks!

### Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.
in B1
put 1

in B2
=IF(A2=A1,B1,B1+1)

In B1 enter the number 1.

In B2 enter this formula and pull down.

Code:
``=IF(A2=A1,B1,B1+1)``

Regards,
Howard

So simple! I'm a little slow today I guess ... thanks for the help

Replies
1
Views
283
Replies
1
Views
297
Replies
7
Views
223
Replies
5
Views
280
Replies
5
Views
447

1,203,380
Messages
6,055,098
Members
444,761
Latest member
lneuberger

### We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.

### Which adblocker are you using?

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

### Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

### Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back