Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
Hi
Can i one of two filters based on code?
Say like if the colour is orange filter by orange table column values but if green then use anoth filter completely?
Any help much appretiated
Andy
Solved! Go to Solution.
Hi @Anonymous ,
Try something like this as per your requirement and data:
Measure= IF(SELECTEDVALUE(TABLE(VALUE))=1, CALCULATE (SUM(Column), filter expression1), CALCULATE (SUM(Column), filter expression2
))
Mark this as a solution if I answered your question. Kudos are always appreciated.
Thanks
Hi
OK, wasn't very explicit, sorry. If you have a tabular model dataset that has 2 tables in it that can be used for filtering, each with its own data that joins to a different column, in a paginated report I need to create DAX queries that will use one or other of the 2 tables, but not both. The 2 don't form a hierarchy, so I can't use it that way. Filtering will be driven by a combination of data and user selection of parameters. This can be achieved fairy easily in SQL, but I need to do it in DAX, it would be sort of like an if value = 1 then use 1 filter if not use the other, which I have tried in DAX and it just errors with a syntax error, in SQL I would use a case statement in the where clause, but I don't know how to do the same in DAX
Any help, much appreciated
Regards
Andy
Hi @Anonymous ,
Try something like this as per your requirement and data:
Measure= IF(SELECTEDVALUE(TABLE(VALUE))=1, CALCULATE (SUM(Column), filter expression1), CALCULATE (SUM(Column), filter expression2
))
Mark this as a solution if I answered your question. Kudos are always appreciated.
Thanks
Hi @Anonymous ,
Yes, you can use two filters.
But I didn't quite understand your question.
Can you please give us an example.
Thanks
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the October 2025 Power BI update to learn about new features.
User | Count |
---|---|
12 | |
11 | |
9 | |
8 | |
8 |