March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.
Register NowGet certified in Microsoft Fabric—for free! For a limited time, the Microsoft Fabric Community team will be offering free DP-600 exam vouchers. Prepare now
Hello,
I am trying to build a Power BI for sports game data. I have some tables such as these two :
They are both related by an fx_code. I created a filter on my dashboard based on the column Team of STATS.
With the value chosen in the filter, I want to keep all these games of MATCHS table (no matter if it is hometeam or awayteam).
So I tried to create a new table like that :
new_table =
var team = SELECTEDVALUE(team)
RETURN FILTER(matchs,OR(matchs[hometeam] = team,matchs[awayteam] = team))
but it returns an empty table and I do not know why ?
Thanks in advance for your help and your time
You can create a relationship between the two tables in Relation View, or merge them through Power Query M using fx_code. Is there a specific visual you are trying to create where the filters are not working. Also, in the model view make sure you set the cross filter direction appropriately. Hope it helps!
User | Count |
---|---|
122 | |
97 | |
89 | |
76 | |
69 |
User | Count |
---|---|
139 | |
115 | |
114 | |
98 | |
98 |