Forum Discussion
Creating a dynamic filter in Matrix table
Hi jainmohit_0710 ,
If you have a filter based on the system name, and that is the filter applied this should pick up the two rows that refer the system 1 name.
Can you give a better explanation on how your model is setup and the relationships between the tables and how the visual is setup? If possible can you please share a mockup data or sample of your PBIX file. You can use a onedrive, google drive, we transfer or similar link to upload your files.
If the information is sensitive please share it trough private message.
- jainmohit_07103 months agoNew Member
MFelix Thanks ...Explanation given above...Apologies due to confidentiality we are not allowed to share actual PBIX
- MFelix3 months agoSuper User
Hi jainmohit_0710 ,
I understand the privacy question can you please just let me know how you have your model setup? Do you have a single table? Is there any relatonships? Were does each column you have on the visualization are coming from?
If you are able to do a smal mockup would be great if not please try and give some insights on the model setup.
- jainmohit_07103 months agoNew Member
Our model is having multiple tables but we need to use only two tables Details and Source system. We are creating Matrix table where we are dragging :
Row - Report ID from Details table
Columns - System name from Source System table
Value - Count of report ID
As advised above we have created a new table in semantic model which is calculating distinc value from Source system table
System Slicer = DISTINCT ( Source_system[System Name] )We have created a measure
Report has Selected System =
Var SelectedSystem =
Values = 'System slicer'[system name]
Return
If(
NOT ISFILTERED ('System slicer'[system name]),
1,
CALCULATE (
COUNTROWS('Details'),
TREATAS (SelectedSystem,
'Source system'[system name]
)
) > 0
)Post that we have dragged the meaure on section filter on visual is 1.
There is no error in measure or matrix table. But when we filter on any specific source system like 1 it had 50 rows then it should show only 50n rows plus other source system associated with those report ID.
Please guide any other way to achieve this solution other than Matrix table will also condisered till it giving results.
Regards
Mohit Jain