I am trying to find the count of all customers who have purchased all of Item 1, 2, and 3. I have tried using the AND filter, however when I use it, it gives me no data. I have also tried using calculated fields and using code to find the distinct count, but none of these approaches work. Is there any way I can find the distinct count of customers who have purchased all of items 1, 2, and 3 like shown in the table below? In this example, the result should be 2 since Customer B and D purchased all of item 1, 2, and 3.
Customer | Item | Purchased? |
---|---|---|
A | Item 1 | 1 |
Item 2 | 0 | |
Item 3 | 1 | |
Item 4 | 0 | |
Item 5 | 1 | |
B | Item 1 | 1 |
Item 2 | 1 | |
Item 3 | 1 | |
Item 4 | 1 | |
Item 5 | 0 | |
C | Item 1 | 0 |
Item 2 | 1 | |
Item 3 | 0 | |
Item 4 | 1 | |
Item 5 | 1 | |
D | Item 1 | 1 |
Item 2 | 1 | |
Item 3 | 1 | |
Item 4 | 0 | |
Item 5 | 1 |