Designing Dynamic Security Models
Dynamic security models in Power BI filter tables are based on the relationship of the logged-in user to a column or columns stored in a semantic model. The USERPRINCIPALNAME
DAX function returns the user’s UPN, and a filter expression of a security role accepts this value as a parameter. Like all filters in Power BI semantic models, the filters applied in security roles also filter other tables via one-to-many and bidirectional relationships. Security roles can also blend dynamic, user-based filters with standard security filters to further restrict the visibility of members mapped to these roles.
This recipe implements dynamic security on an Employees
dimension table. The result is that logged-in users (employees) can only view their own data and that of those who report to them directly or indirectly via other managers.
When implementing this scenario within your own semantic models, first establish the technical feasibility of dynamic...