# Solved: sequential row numbering based on value in another column/cell

Discussion in 'Business Applications' started by mdiego, Dec 21, 2011.

Not open for further replies.

Joined:
Dec 21, 2011
Messages:
12
I need to provide seqential row numbers from 1 to N that relate to cells in another column when the cell value is greater than zero. For instance, if the column with data is column d and I have data greater than zero in cells d3, d4, d5, and d7 I'd like the row count in column c to read number 1 for c3, 2 for c4, 3 for c5, and 4 four c7. Cells c1 through c3 as well as c6 should remain blank. What formula do I use?

2. ### etafModerator

Joined:
Oct 2, 2003
Messages:
64,891
First Name:
Wayne
Try this in Cell C2

=IF(D2>0, MAX(\$C\$1:C1)+1,"")

and then copy down all the rows that you want to test

Joined:
Dec 21, 2011
Messages:
12
All that gives me is a number 1 in each cell in column C corresponding to the cells in column D where there's data >1. There's no sequential numbering, such as 1, 2, 3

4. ### etafModerator

Joined:
Oct 2, 2003
Messages:
64,891
First Name:
Wayne
worked for me
see attached - i may not have understood

#### Attached Files:

• ###### seq_etaf.xls
File size:
14.5 KB
Views:
43

Joined:
Dec 21, 2011
Messages:
12
Genius! It works!!!!!!

6. ### etafModerator

Joined:
Oct 2, 2003
Messages:
64,891
First Name:
Wayne
not sure why it did not work for you first time

thanks for letting us know
You can mark your own threads solved using the button at the top of the page of the thread in the upper left corner.

As Seen On