• 544K Members
• 4,098 Online
• 648K Conversations
SOLVED

## Running count of matching numbers (or text)

Highlighted
Occasional Contributor

# Running count of matching numbers (or text)

Hello! I fear this may be a simple question, but I don't know how to phrase it correctly to find an answer.

I cannot figure out how to calculate a running count for a row of items that have duplicates. I've attached an example. I'm trying to calculate the highlighted row. I'm trying to get pivot tables to do it for me, but using the Running count function I just get a bunch of 1s.

Any help is appreciated!

3 Replies
Highlighted

# Re: Running count of matching numbers (or text)

@Ian_4-learnin , that could be like

`=(N(D2)+1)*(\$B3=\$B2)+(\$B3<>\$B2)`

It adds 1 if the value in B is the same and returns 1 otherwise

Highlighted
Solution

# Re: Running count of matching numbers (or text)

`=COUNTIFS(B\$3:B3,B3)`

# Re: Running count of matching numbers (or text)

@Sergei BaklanThank you, that works great. Now I just have to study a little and figure out what it means...

Related Conversations
Counting Days
Tim Hunter in SQL Server on
2 Replies
How to count multiple values in a cell
Ugarte335 in Excel on
7 Replies
Count until
MBelshaw in Excel on
1 Replies
Pivot table
gabriellerocha in Excel on
5 Replies