List unique values and count cell values with different conditions

nahaku

Board Regular
Joined
Mar 19, 2020
Messages
106
Office Version
  1. 365
  2. 2019
Platform
  1. Windows
Hello, I im trying to find formulas to help me make statistics, but I do not know how to get this. The formulas I found on internet helps always only with half of the problem.
I am trying to list unique value from [A] Yelow column for example GBL0004,GBS0083,...
then it could list GBL0004 divided by Region name from Column Blue column so for example GBL0004 A , GBS0083 A, GBS0083 C1, GBS0083 B1,GBS0088 A, GBS0088 B1 ....
it basically splits the person by location where they ware working.
and then just count with Brown Columns separetly. That is somethink i might do, but I am not able to count it with that condition so it would count for unique
IF (Picker [A]+ Region name ) = SUM(C:C) { or Sum D, E, F, G......}
 

Attachments

  • 689E3629-D047-4a5d-A385-9866F9F7D84A.png
    689E3629-D047-4a5d-A385-9866F9F7D84A.png
    53.9 KB · Views: 16
You could use a list like
+Fluff.xlsm
ABCDEFGHI
1CountyWard
2CumbriaACheshireDerbyshireA
3DerbyshireACumbriaWest YorkshireB
4DerbyshireASomersetDerbyshireB
5West YorkshireBWest YorkshireC
6DerbyshireBDerbyshireC
7DerbyshireBStaffordshireC
8West YorkshireCDerbyshireD
9DerbyshireCWest YorkshireE
10StaffordshireCGreater ManchesterE
11DerbyshireDWest YorkshireF
12DerbyshireDStaffordshireA
13CheshireDShropshireB
14West YorkshireECounty DurhamB
15Greater ManchesterELancashireC
16West YorkshireENorthumberlandD
17West YorkshireFLancashireD
18West YorkshireFSouth YorkshireD
19West YorkshireFDerbyshireE
20StaffordshireACounty DurhamF
21SomersetA
22CumbriaA
Data
Cell Formulas
RangeFormula
G2:H20G2=UNIQUE(FILTER(FILTER(A2:C37,(COLUMN(A2:C2)=1)+(COLUMN(A2:C2)=3)),ISERROR(MATCH(A2:A37,E2:E4,0))))
Dynamic array formulas.
 
Upvote 0

Excel Facts

Excel Wisdom
Using a mouse in Excel is the work equivalent of wearing a lanyard when you first get to college
You're welcome & thanks for the feedback
 
Upvote 0
I tried to use your function, but instead of ignoring the Values from the Table on side, I would want to use this time only those values. It is kind a working but for some reason when i added data from different date, it was showing also values for GBS0203 , even when it is not in my list, and all other values what I do not want in my Tab are ignored... Weird.

End of day report.xlsx
ABCDEFGHIJKL
1PickerZoneOcsSKUsTime PcsAvarage TRepicksWeightVolume
2GBS0183D3129651024760447632854231.4603.501412.309987GBS0166
3GBS0183D226843265053430616.4000.121750.5224799GBS0183
4GBS0183LE341157284507525541.9200.093640.3961211GBS0184
5GBS0183D3,D2375173224833725310.1100.202021.0498044GBS0184
6GBS0183D2,LE,D37032180810971864.0200.033390.1245715GBS0185
7GBS0183D2,D319350207628734282.8700.041160.1837786GBS0190
8GBS0183LE,D3985104279748748.7800.133610.2139432GBS0192
9GBS0183D3,LE72121193992129.7700.012330.0226128GBS0196
10GBS0203C12847478328416.8433.012527.624641GBS0218
11GBS0203B11019921099.2000.1751.52134GBS0219
12GBS0203B25015495010.9800.9153.4056GBS0221
13000000#DIV/0!000GBS0225
140000#DIV/0!000GBS0226
150000#DIV/0!000GBS0227
160000#DIV/0!000GBS0228
170000#DIV/0!000GBS0229
180000#DIV/0!000GBS0230
190000#DIV/0!000GBS0234
200000#DIV/0!000GBS0235
Picker Stat.
Cell Formulas
RangeFormula
A2:B13A2=UNIQUE(FILTER(FILTER(PSdata!$B$2:$E$508,(COLUMN(PSdata!$B2:$E2)=2)+(COLUMN(PSdata!$B2:$E2)=5)),ISERROR(MATCH(PSdata!B2:B508,L2:L20,-1))))
C2:C20C2=SUMIFS(PSdata!O:O,PSdata!$B:$B,$A2,PSdata!$E:$E,$B2)
D2:D20,F2:F20D2=SUMIFS(PSdata!N:N,PSdata!$B:$B,$A2,PSdata!$E:$E,$B2)
E2:E20E2=SUMIFS(PSdata!K:K,PSdata!$B:$B,$A2,PSdata!$E:$E,$B2)
G2:G20G2=E2/F2
H2:H20H2=SUMIFS(PSdata!M:M,PSdata!$B:$B,$A2,PSdata!$E:$E,$B2)
I2:J20I2=SUMIFS(PSdata!Q:Q,PSdata!$B:$B,$A2,PSdata!$E:$E,$B2)
Dynamic array formulas.
Cells with Conditional Formatting
CellConditionCell FormatStop If True
L2:L20Cell ValueduplicatestextNO
L2:L20Cell ValueduplicatestextNO
L2:L20Cell ValueduplicatestextNO
L2:L20Cell ValueduplicatestextNO
 
Last edited by a moderator:
Upvote 0
I followed the guide how to import it but it does not work...
I tried to use your function, but instead of ignoring the Values from the Table on side, I would want to use this time only those values. It is kind a working but for some reason when i added data from different date, it was showing also values for GBS0203 , even when it is not in my list, and all other values what I do not want in my Tab are ignored... Weird.

=UNIQUE(FILTER(FILTER(PSdata!$B$2:$E$508,(COLUMN(PSdata!$B2:$E2)=2)+(COLUMN(PSdata!$B2:$E2)=5)),ISERROR(MATCH(PSdata!B2:B508,L2:L20,-1))))

I tried XMATCH with 0 , but then I got No output...
 

Attachments

  • 1.png
    1.png
    53.5 KB · Views: 6
Upvote 0
I followed the guide how to import it but it does not work...
After pasting the XL2BB code in your reply, I think you had (accidentally?) selected some of the code and clicked the strikethrough icon above the Reply window
1585299652578.png


I have fixed it for you.
 
Upvote 0
heh do not know how that happend, I tried it like 10 times with preview, and it was every single time. So i thought preview was broken :P
 
Upvote 0
heh do not know how that happend, I tried it like 10 times with preview, and it was every single time. So i thought preview was broken :P
Suggest that you go to the Test Here forum and have a practice or two to see if you can get XL2BB working.
 
Upvote 0
You're welcome & thanks for the feedback
Sorry to bother again, I tried to adjust the formula for another purpose, and when i use
=UNIQUE(FILTER(FILTER(PSdata!$B$2:$E$508,(COLUMN(PSdata!$B2:$E2)=2)+(COLUMN(PSdata!$B2:$E2)=5)),ISERROR(MATCH(PSdata!B2:B508,AG5:AG24,-1))))
It will list only GBS names what are in the list on Right side in post number #14. But for some reason it still Shows in Tab GBS0203, even when it is not in my list.
To me it looks like it is showing values close to values of my list. I tried to use XMATCH function instead of MATCH but either it was same result or I got error. Do you have any advice?
I now need just to extract names what are in the DATA if they are in my list on the right side of post #14 :{
 
Upvote 0
Try
=UNIQUE(FILTER(FILTER(PSdata!$B$2:$E$508,(COLUMN(PSdata!$B2:$E2)=2)+(COLUMN(PSdata!$B2:$E2)=5)),NOT(ISERROR(MATCH(PSdata!B2:B508,L2:L20,0))))
 
Upvote 0

Forum statistics

Threads
1,215,719
Messages
6,126,432
Members
449,314
Latest member
MrSabo83

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