Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
petetai
Regular Visitor

Apply AND logic to filter a visualisation using multiple selections in another

Hi,

 

A very simplified version of my database has three tables:
* Stops stores the locations of bus stops (primary key: StopID)

* Journeys stores the details of various passenger journeys (e.g. start time, origin, destination and primary key JourneyID)

* StopJourneyMap lists which journeys go past which stops. I.e. it has just two columns: StopID and JourneyID

 

Ultimately what I'd like to do is let the user select some stops in a table visualisation and then in a map visualisation show the origins and destinations of journeys that go past those selected stops.

 

Crucially though I'd like to show only the journeys that go past ALL of the selected stops. Currently I'm struggling with that first step. I've got two table visualisations - One that shows the Stops table and another that shows the StopJourneyMap table. When the user clicks on a row in the Stops table visualisation, it filters the StopJourneyMap to show which journeys go through that stop, which is fine. However, when the user selects another stop (Ctrl+click), the StopJourneyMap table is filtered to show all journeys that go through either stop. How can I change that behaviour so that the StopJourneyMap table is filtered to show only journeys that go through *both* the selected stops?

2 REPLIES 2
v-chuncz-msft
Community Support
Community Support

@petetai,

 

Try using INTERSECT Function in your measure.

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.
petetai
Regular Visitor

Still struggling with this. I created a measure that calculates how many stops have been selected and a then tried to apply this as a filter to filter for routeIDs that are associated with that many stops. But I couldn't get this to work. So perhaps measures were a red herring.

 

I'd be grateful for any pointers.

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

60 days of Data Days Carousel

Data Days 2026

Join Fabric Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.