Forum Discussion
Anonymous
8 years agoNot applicable
How to set row level security customer company code linked to login ID
Environment is Power BI embedded and Azure SQL One table has all customer company data contain customer company code and users will access common Power BI Report. Login ID does not contain compan...
- Anonymous8 years ago
Hi Anonymous,
For your scenario, you can set up your RLS fitler on company_code filed.
Lookup company_code based on current username, then use this as filter parameter to apply on company_code field.
Sample formula:
[company_code] = LOOKUPVALUE ( 'Table'[company_code], 'Table'[login_Id], USERPRINCIPALNAME () )
Regards,
Xiaoxin Sheng
Anonymous
8 years agoNot applicable
Hi Anonymous,
I'd like to suggest you to take a look at below link about RLS with username:
Add company code to user table to link company id with username and use this column to create relationship to other tables. Then you can use logined users to achieve dynamic rls filter.
Regards,
Xiaoxin Sheng