Count unique values where multiple columns have data

Spartin

New Member
Joined
Feb 25, 2014
Messages
35
See below. I need to count the number of drivers (identified by their unique driver ID in ColumnA) who logged into a system over the given date range (in columns B-E). In the example below, the answer is 2. I'm having trouble counting the unique values given the multiple columns. Any help is appreciated. I am having problems with the formatting on the table below - sorry for about that.


A B C D E
Driver ID 7/1/17 7/2/17 7/3/17 7/4/17

1010003 1 1
1010008
1010011
1010013
1010118 1 1 1
1010121
1010128
 
Last edited:

Excel Facts

Using Function Arguments with nested formulas
If writing INDEX in Func. Arguments, type MATCH(. Use the mouse to click inside MATCH in the formula bar. Dialog switches to MATCH.
This board contains zillions frequency formulas for doing a unique count.

If the items to count are not just numbers...

Control+shift+enter:

=SUM(IF(FREQUENCY(IF(1-(A2:A8),IF(ISNUMBER(B2:E8),MATCH(A2:A8,A2:A8,0))),ROW(A2:A8)-ROW(A2)+1),1))

I tried using this and it doesn't seem to work for me. If the IDs are names and not numbers, then 1-(A2:A8) results in an error that is carried through the rest of the formula.

EDIT: In fact removing that IF statement solves the issue and the formula seems to work fine.
 
Last edited:
Upvote 0
I tried using this and it doesn't seem to work for me. If the IDs are names and not numbers, then 1-(A2:A8) results in an error that is carried through the rest of the formula.

EDIT: In fact removing that IF statement solves the issue and the formula seems to work fine.

It’s

1-(A2:A8=“”)
 
Upvote 0

Forum statistics

Threads
1,224,827
Messages
6,181,200
Members
453,022
Latest member
RobertV1609

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