Forum Discussion
OPTIMIZE DAX MEASURE
Hi Anonymous
Where did you use this measure? It seems this measure is not used in the Table filter DAX expression box for RLS.
For Row level security, the DAX expression entered in the Table filter DAX expression box should return a value of true or false. For example: [Entity ID] = “Value”. This is used to filter rows according to the true or false result. According to your table, you can try a DAX expression like [User] = username() .
In addition, you can create relationships between tables. Relationships can pass filters between tables. This is more efficient than using LOOKUPVALUE function.
Here are some RLS tutorials for your reference. Note that if you want to use username() or userprincipalname(), this is dynamic RLS.
How to Setup Static and Dynamic Row Level Security (RLS) in Power BI?
Hope this helps.
Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.
- Anonymous4 years agoNot applicable
Hello, v-jingzhang !
I use this measure in SSAS, in my tabular model.
I don't have active this option in my PowerBi.
I need to implement rls for:
1. Dynamic filtering. When a user from one division enters, the information associated with the division should be filtered automatically.
2. Static filtering. When a management user enters, he can view all the divisions and filter the information in the interface.For first i use measure in Rols -> SSAS.
For second i use relationships:
In this moment, works. But not very fast when i apply dynamic RLS.