Customer Count per Week

joand

Active Member
Joined
Sep 18, 2003
Messages
266
I have a table with columns: Team, Date, Customer, Task Description, Time, and Week Number. I want to count the number of instances a customer appears on a single week. My issue is that there are instances wherein a customer appears multiple times on a given day. It should count only as 1 per day. For example, in the table below, the total count for customer 1A for Week 27 should only be 1 not 2 for Team A. For customer 1B, the total count should be 2 for Team A since 7/3 and 7/4 are different dates and they belong to week 27. I need the customer count per week per team. Any ideas?

TeamDateCustomerTask DescriptionTimeWkNum
A07/03/20231AXXX327
A07/03/20231AXXX427
A07/03/20231BXXX427
A07/04/20231BXXX227
A07/04/20232AXXX427
B07/03/20232AXXX127
B07/04/20232AXXX327
B07/04/20232AXXX127
C07/05/20232BXXX427
C07/05/20232BXXX227
C07/05/20232BXXX127
C07/05/20232BXXX227
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
Check this -

Book1
ABCDEFGH
1TeamDateCustomerTask DescriptionTimeWkNumCountCount Wk
2A7/3/231AXXX32711
3A7/3/231AXXX42701
4A7/3/231BXXX42712
5B7/3/232AXXX12712
6A7/4/231BXXX22712
7A7/4/232AXXX42712
8B7/4/232AXXX32702
9B7/4/232AXXX12702
10C7/5/232BXXX42711
11C7/5/232BXXX22701
12C7/5/232BXXX12701
13C7/5/232BXXX22701
Sheet1
Cell Formulas
RangeFormula
G2:G13G2=IFS(COUNTIFS($B$2:B2,B2,$C$2:C2,C2)>1,0,TRUE,COUNTIFS($B$2:B2,B2,$C$2:C2,C2))
H2:H13H2=SUMIFS($G$2:$G$13,$C$2:$C$13,C2,$F$2:$F$13,F2)
 
Upvote 0
Hi, could you include Team in the parameter?
Try it and revert -

Book2
ABCDEFGH
1TeamDateCustomerTask DescriptionTimeWkNumCountCount Wk
2A451101AXXX32711
3A451101AXXX42701
4A451101BXXX42712
5B451102AXXX12712
6A451111BXXX22712
7A451112AXXX42711
8B451112AXXX32712
9B451112AXXX12702
10C451122BXXX42711
11C451122BXXX22701
12C451122BXXX12701
13C451122BXXX22701
Sheet1
Cell Formulas
RangeFormula
G2:G13G2=IFS(COUNTIFS($B$2:B2,B2,$C$2:C2,C2,$A$2:A2,A2)>1,0,TRUE,COUNTIFS($B$2:B2,B2,$C$2:C2,C2,$A$2:A2,A2))
H2:H13H2=SUMIFS($G$2:$G$13,$C$2:$C$13,C2,$F$2:$F$13,F2,$A$2:$A$13,A2)
 
Upvote 0
Solution

Forum statistics

Threads
1,215,143
Messages
6,123,282
Members
449,094
Latest member
GoToLeep

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