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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
ivanmezev
Frequent Visitor

bidirectional filtering not working

I have a fact table and dim_games table connected through game_id in bidirectional relationship. I have game_name as a filter for all pages coming from the dim_games table. I want to see only those games in the filter which have sales(data) in the fact table. Eventhough the connection is bidirectional I still see all games. Why the bidirecitonal filter is not propagated from the fact to the dim table? I want to achive this with filters and not slicers.

Thanks

1 ACCEPTED SOLUTION
Dezmond95
Frequent Visitor

I'm assuming you have a situation where you have 3 games with sales (A, C, and E) and 2 with no sales (B and D) but if you add the Dim_Games table Game Name to the filter panel, you are seeing all games like in the first when you only want it to show A,C, and E like in the second image.

 

Current.PNG

 

If this is the goal where you can only see those with sales in the filter panel (plus blank for some reason), I used a helper table.

With Helper Table.PNG

 

The helper table is made using this dax code. It basically filters the Dim_Games table and only displays the Game_Name with sales greater than 0 (sales = sum(fact_table[sales]) and the Game ID.

 

Helper Table.PNG

 

This is so we can create a 1:* (1 to many) relationship from this new table to the fact table using the Game ID column. I also tested that it would add new game names if B suddenly had sales, it also showed up in the helper table during refresh.

 Model View.PNG

Im hoping this helps.

View solution in original post

4 REPLIES 4
Dezmond95
Frequent Visitor

I'm assuming you have a situation where you have 3 games with sales (A, C, and E) and 2 with no sales (B and D) but if you add the Dim_Games table Game Name to the filter panel, you are seeing all games like in the first when you only want it to show A,C, and E like in the second image.

 

Current.PNG

 

If this is the goal where you can only see those with sales in the filter panel (plus blank for some reason), I used a helper table.

With Helper Table.PNG

 

The helper table is made using this dax code. It basically filters the Dim_Games table and only displays the Game_Name with sales greater than 0 (sales = sum(fact_table[sales]) and the Game ID.

 

Helper Table.PNG

 

This is so we can create a 1:* (1 to many) relationship from this new table to the fact table using the Game ID column. I also tested that it would add new game names if B suddenly had sales, it also showed up in the helper table during refresh.

 Model View.PNG

Im hoping this helps.

Thanks, this is exactly what I need. Not sure how fast it will be with millions of rows in the fact table but I'll test it.

Anonymous
Not applicable

Hi, @ivanmezev 

 

Based on your description, you want to implement filtering of sold games. I have created some measures to achieve the effect you are looking for. You can add this measure to the filter pan. Following picture shows the effect of the display.

Before:

vyaningymsft_0-1710490144437.png

 

After:

vyaningymsft_3-1710490211872.png

 

Measure:

Measure = 
VAR _dim_game_id = SELECTEDVALUE(dim_games[game_id])

VAR _result = 
IF (
    COUNTROWS ( FILTER ( 'fact', 'fact'[game_id] = _dim_game_id ) ) > 0,
    1,
    BLANK ()
)

RETURN
_result


Best Regards,
Yang
Community Support Team

 

If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

How to get your questions answered quickly --  How to provide sample data in the Power BI Forum

 

 

 

Hi, Thanks for your reply but this is not exactly what I need.

If I use your example I don't want to see B and D in the game's filter because they don't have sales

 

ivanmezev_1-1710492321861.png

 

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors