Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
We have Student Details (fact table) and Subject Details (Dim Table). Each Student has many subjects. Subject Name from Subject Details as slicer.
StudID | StudName | Sub Name |
233 | Jake | English |
233 | Jake | Computer |
233 | Jake | Physics |
234 | Nick | Computer |
234 | Nick | Physics |
235 | Hana | Physics |
235 | Hana | English |
235 | Hana | Computer |
SubID | SubName |
1 | English |
2 | Computer |
3 | Physics |
If we select "English" from subject slicer, filter rows with students who do not have "English" subject associated.
Expected Output:
234 | Nick | Computer |
234 | Nick | Physics |
Something like
select * from Student details
where StudID not in
(select StudID from Student details where SubName = "English")
Solved! Go to Solution.
Hi, @Rash
Create a new measure:
Countrows =
CALCULATE (
COUNTROWS ( 'Student Details' ),
ALLEXCEPT ( 'Student Details', 'Student Details'[StudID] ),
'Student Details'[Sub Name] IN VALUES ( 'Subject Details'[SubName] )
) + 0
//Count the rows containing the associated SubName in each Stud
//Result 0 means that current student does not contain related records.
and then apply this measure to the visual filter pane like:
Best Regards,
Community Support Team _ Eason
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thanks a lot. This worked as expected.
Hi, @Rash
Create a new measure:
Countrows =
CALCULATE (
COUNTROWS ( 'Student Details' ),
ALLEXCEPT ( 'Student Details', 'Student Details'[StudID] ),
'Student Details'[Sub Name] IN VALUES ( 'Subject Details'[SubName] )
) + 0
//Count the rows containing the associated SubName in each Stud
//Result 0 means that current student does not contain related records.
and then apply this measure to the visual filter pane like:
Best Regards,
Community Support Team _ Eason
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
109 | |
99 | |
77 | |
66 | |
54 |
User | Count |
---|---|
144 | |
104 | |
102 | |
87 | |
64 |