Counting unique entries per mon - formula help

DaveR

Board Regular
Joined
May 10, 2006
Messages
176
I am trying to calculate how may unique enteries there are per month.

I currently callucalte the total with;

=SUMPRODUCT((MONTH('Front Sheet'!$H$3:$H$292)=4)*(YEAR('Front Sheet'!$H$3:$H$292)=2011))

The list would be contained in column B (i.e the number of unique entries).
 

Excel Facts

Whats the difference between CONCAT and CONCATENATE?
The newer CONCAT function can reference a range of cells. =CONCATENATE(A1,A2,A3,A4,A5) becomes =CONCAT(A1:A5)
I am trying to calculate how may unique enteries there are per month.

I currently callucalte the total with;



The list would be contained in column B (i.e the number of unique entries).
The formula you have counts the April 2011 dates. Are you requesting a formula to determine the number of different (distinct) dates in April 1011? If so:

Let A2 house 4 and B2 2011.

C2, control+shift+enter, not just enter...
Code:
=SUM(IF(FREQUENCY(
    IF('Front Sheet'!$H$3:$H$292<>"",
    IF(MONTH('Front Sheet'!$H$3:$H$292)=A2,
    IF(YEAR('Front Sheet'!$H$3:$H$292)=B2,
      MATCH('Front Sheet'!$H$3:$H$292,'Front Sheet'!$H$3:$H$292,0)))),
        ROW('Front Sheet'!$H$3:$H$292)-ROW('Front Sheet'!$H$3)+1),1))

In D2, you could enter a revised version of the SumProduct formula...
Code:
=SUMPRODUCT(
   --(MONTH('Front Sheet'!$H$3:$H$292)=A2),
   --(YEAR('Front Sheet'!$H$3:$H$292)=B2))
 
Upvote 0
Thanks for this.

I did realise after posting that I already had a way to do it contained in the sheet.

I have a column C with;

=SUM(COUNTIF($B$3:$B$309,$B$3:$B$309))

Which then gives me an easy option to calculate the unique entries with;

=SUMPRODUCT((MONTH('Front Sheet'!$H$3:$H$292)=4)*(YEAR('Front Sheet'!$H$3:$H$292)=2011)*(('Front Sheet'!$C$3:$C$292)=1))

I'm still trying to work out which is quicker (we are on a citrix server and speed is vital)
 
Upvote 0

Forum statistics

Threads
1,224,550
Messages
6,179,459
Members
452,915
Latest member
hannnahheileen

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