The ultimate Microsoft Fabric, Power BI, Azure AI, and SQL learning event! Join us in Stockholm, Sweden from September 24-27, 2024.
2-for-1 sale on June 20 only!
Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
How to anonymize a certain column for a certain usergroup? This is my model:
A user should always be able to see only their CostCenter. I've fixed that with an RLS function and a relationship between the tables RLS and Department [Username] = userprincipalname().
My issue is that for anyone with the flag asp_rep = 1 in my RLS-table, I need to somehow anonymize the name column in the Fact_Consultation table. I don't have a preferred method, but I'm thinking of using some sort of IF/Switch statement. However, that's where my knowledge stops. How could I achieve such a result? Data export, etc. is already limited for everyone, so it's enough if it's just a visual layer of security.
RLS-table
CostCenter | Username | asp_rep |
111 | aaa.aaa@mail.com | 1 |
111 | bbb.bbb@mail.com | 0 |
222 | ccc.ccc@mail.com | 0 |
Wanted result when vieing the report as a user with asp_rep = 0
Name | Sold amount |
Tom Hanks | 5 185 |
Brad Pitt | 1 849 |
Jennifer Lawrence | 19 598 |
Emily Blunt | 17 874 |
Wanted result when vieing the report as a user with asp_rep = 1
Name | Sold amount |
101 | 5 185 |
102 | 1 849 |
103 | 19 598 |
104 | 17 874 |
Hi, @eaj
Please refer to the following links in the hopes of helping you.
Solved: Dynamic RLS - Microsoft Power BI Community
Row Level Security with SSAS Tabular Live Connection in Power BI - RADACAD
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.
Check out the June 2024 Power BI update to learn about new features.
User | Count |
---|---|
106 | |
102 | |
82 | |
62 | |
56 |
User | Count |
---|---|
254 | |
119 | |
115 | |
100 | |
76 |