counting/numbering with 2 or more colums?

atanatashi

New Member
Joined
Aug 5, 2014
Messages
3
Hi, is it possible to count/numbering with two columns as its range?

i wanted a numbering on the dates as shown below;
the countif formula works but on one column only, how can i add the other column so it does not only count the date 1 column but also the date 2 column where the answer should be the bold numbers. thanks

#DATE 1DATA#DATE 2DATA
COUNTIF($C$2:C2,C2)17/4/2014XXXX57/4/2014XXXX
COUNTIF($C$2:C3,C3)27/4/2014XXXX27/7/2014XXXX
COUNTIF($C$2:C4,C4)37/4/2014XXXX17/8/2014XXXX
47/4/2014XXXX27/8/2014XXXX
17/7/2014XXXX27/9/2014XXXX
17/9/2014XXXX37/9/2014XXXX
17/10/2014XXXX27/10/2014XXXX
17/11/2014XXXX37/11/2014XXXX
27/11/2014XXXX47/11/2014XXXX

<tbody>
</tbody>
 

Excel Facts

Move date out one month or year
Use =EDATE(A2,1) for one month later. Use EDATE(A2,12) for one year later.
Hi, thanks for the reply. if I include the whole range it will count the criteria in C2 which is 7/4/2014 which results to 5.
what i need is to create a numbering sequence, where it will counts the number of occurrence every time the criteria is met. example from ($C$2:C2,C2) it will count first, ($C$2:C3,C3) it will count second, ($C$2:C4,C4) will count third so on and so forth since the criteria is still the same, till a new criteria is met which in this case ($C$2:C6,C6) it will count 1 since that's the first 7/7/2014 on the range. doing this in one column of range gives me the correct counting/numbering, i don't know how to do it in 2 or more columns. is this possible? thanks again.
 
Upvote 0
Not sure if I understand what you need

See if this is Ok


A
B
C
D
E
F
1
#​
DATE 1​
DATA​
#​
DATE 2​
DATA​
2
1​
07/04/2014​
XXXX​
5​
07/04/2014​
XXXX​
3
2​
07/04/2014​
XXXX​
2​
07/07/2014​
XXXX​
4
3​
07/04/2014​
XXXX​
1​
07/08/2014​
XXXX​
5
4​
07/04/2014​
XXXX​
2​
07/08/2014​
XXXX​
6
1​
07/07/2014​
XXXX​
2​
07/09/2014​
XXXX​
7
1​
07/09/2014​
XXXX​
3​
07/09/2014​
XXXX​
8
1​
07/10/2014​
XXXX​
2​
07/10/2014​
XXXX​
9
1​
07/11/2014​
XXXX​
3​
07/11/2014​
XXXX​
10
2​
07/11/2014​
XXXX​
4​
07/11/2014​
XXXX​

Formula in A2 copied down
=COUNTIF(B$2:B2,B2)

Formula in D2 copied down
=COUNTIF(E$2:E2,E2)+COUNTIF($B$2:$B$10,E2)

Hope this helps

M.
 
Upvote 0
oMYGlob! it works! thank you so much Marco! i tried adding 2 countifs before but got the ranges wrong.. thanks again this is a big help. :)
 
Upvote 0

Forum statistics

Threads
1,216,030
Messages
6,128,408
Members
449,448
Latest member
Andrew Slatter

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.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

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

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

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
Back
Top