The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello,
I have the following tables:
data table:
ID | C1 | C2 | C3 | D1 | D2 | NAT |
1 | A | B | ||||
2 | B | C | D | |||
3 | A | |||||
4 | B | |||||
5 | Z | |||||
6 | X | |||||
7 | 1 | |||||
8 | 1 |
geo table:
LocationCode | Location | SubLocation |
1 | A | |
2 | B | |
3 | Z | C |
4 | D | |
5 | E | |
6 | X | G |
7 | NAT |
I have a slicer that lists the location and when i choose a location, i want to filter my main table through the columns of C1 to C3 and NAT. I've tried unpivoting the C1 C2 and C3 columns and using that as an intermediate table to connect all of the tables, but i'm not sure how i can do the same with the NAT and D1,D2 columns.
Thank you.
I've tried unpivoting the C1 C2 and C3 columns and using that as an intermediate table to connect all of the tables, but i'm not sure how i can do the same with the NAT and D1,D2 columns.
Do the same - unpivot everything except the ID column. Then in DAX you can implement the logic that checks for either location or sublocation matches.