Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi. I have a measure slicer that I have manually created
There is a table:
Title. Number
Choice1 1
Choice2 2
Choice3 3
A measure which I am using as a slicer:
SWITCH(
[Selected Measure],
1, SUM('Table'[Choice1]),
2, SUM('Table'[Choice2]),
3, SUM('Table'[Choice3]))
And I have a table visual with many columns, including
'Table'[Choice1 Y] which is either 1 or null
'Table'[Choice2 Y] which is either 1 or null
'Table'[Choice3 Y] which is either 1 or null
I want my. table to filter the rows to only show the rows where the selected value(s) are not equal to null. But right now I am getting everything and the table isn't filtering. Is there a way to only filter (where Choice1 Y = 1, for example) if selected?
I found this formula to hide the other columns if they are not selected, but that still does not filter the rows. Any suggstions on how to accomplish this? Note that if I put these field in the visual filters for the table, in selecting instances where Choice1 = Y (1), for example, I am also removing records from Choice2 and Choice3 that shouldn't be removed, if I apply those filters as well.
Solved! Go to Solution.
Hi @jupyter ,
If you want to filter the rows of your table based on the selected measure value in your slicer, you can use a combination of the SELECTEDVALUE function and the ISFILTERED function in a calculated column to achieve this.
Here is an example of how you can create the calculated column:
Filter Column =
IF (
ISFILTERED ( 'Table'[Choice1 Y] ),
SELECTEDVALUE ( 'Selected Measure' ),
BLANK ()
)
This calculated column will return the selected measure value from the slicer if Choice1 Y is filtered, and BLANK() otherwise. You can then use this calculated column as a filter on your table visual to only show the rows where the selected measure value is not BLANK().
If the problem is still not resolved, please provide detailed error information and test data. Looking forward to your reply.
Best Regards,
Henry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @jupyter ,
If you want to filter the rows of your table based on the selected measure value in your slicer, you can use a combination of the SELECTEDVALUE function and the ISFILTERED function in a calculated column to achieve this.
Here is an example of how you can create the calculated column:
Filter Column =
IF (
ISFILTERED ( 'Table'[Choice1 Y] ),
SELECTEDVALUE ( 'Selected Measure' ),
BLANK ()
)
This calculated column will return the selected measure value from the slicer if Choice1 Y is filtered, and BLANK() otherwise. You can then use this calculated column as a filter on your table visual to only show the rows where the selected measure value is not BLANK().
If the problem is still not resolved, please provide detailed error information and test data. Looking forward to your reply.
Best Regards,
Henry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
User | Count |
---|---|
77 | |
75 | |
46 | |
31 | |
28 |
User | Count |
---|---|
99 | |
91 | |
51 | |
49 | |
46 |