Forum Discussion
Using a card visualization with if/else statement
Hi all.
I have a card on a power bi report that I want to update based on row-level-security (RLS). The RLS is set up to filter my data on the field "county." Each RLS role only displays data for a single county.
When there is no RLS rules selected, I want the card to say "all counties". When RLS is selected, I want the card to only display the name of the county filtered. I'm using this measure to display in the card:
mossshvlw yes because when RLS is applied it is not seeing that table isfiltered even thru RLS it is filtered as one country
change ISFILTERED To HASONEVALUE
Check my latest blog post Compare Budgeted Scenarios vs. Actuals I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.⚡
2 Replies
- parry2kSuper User
mossshvlw yes because when RLS is applied it is not seeing that table isfiltered even thru RLS it is filtered as one country
change ISFILTERED To HASONEVALUE
Check my latest blog post Compare Budgeted Scenarios vs. Actuals I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.⚡
- mossshvlwHelper II
Thanks. This worked, but what exactly is RLS doing then? Is RLS actually filtering the table?