cancel
Showing results for
Did you mean:
Member

## Fiiltering table visualisations - I need "AND"

The data we're working with is relatively simple. We have a webform people have filled out at different times with different answers in them. The answers are structured (dropdown choices), so there's only a few different values in the column.

The table we have is made up of columns FormID, Date, Answer

What I need is to find the number of FormID based on the answer value (or values, using CTRL-click) that I chose in the report, table visualisation.

Easy enough, until I choose two Answer values.

PowerBI gives me the number of FormID that have the first answer, PLUS the number that have the second.

What I need is how many have the first AND the second when I click on two (or three, etc).

It sounded really simple when I started the report, but it's anything BUT 🙂

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Support Team

## Re: Fiiltering table visualisations - I need "AND"

You may refer to the measure below.

Measure =
COUNTROWS (
FILTER (
VALUES ( Table1[FormID] ),
CALCULATE (
DISTINCTCOUNT ( Table1[Answer] ) = COUNTROWS ( ALLSELECTED ( Table1[Answer] ) )
)
)
)
Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
3 REPLIES 3
Highlighted
Community Support Team

## Re: Fiiltering table visualisations - I need "AND"

You may refer to the measure below.

Measure =
COUNTROWS (
FILTER (
VALUES ( Table1[FormID] ),
CALCULATE (
DISTINCTCOUNT ( Table1[Answer] ) = COUNTROWS ( ALLSELECTED ( Table1[Answer] ) )
)
)
)
Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Member

## Re: Fiiltering table visualisations - I need "AND"

Thank you SO much! You've just given us the solution to a LOT of other problems we have here - cheers 🙂

Frequent Visitor

## Re: Fiiltering table visualisations - I need "AND"

My scenario is a little different.  I have a Unit table and an Option table,  I need to be able to find all of the units that do not have the selected option, options.  This works great for finding all of the units that DO contain the selected option but I also need to find all the units that do not match the seleted option.  I tried changing the = to <> but that did not work. How could I do this?  Thank You Very Much

Announcements