Forum Discussion
USERPRINCIPALNAME() with PBI Dataset as source
- 6 years ago
Anonymous
You can typically override the result returned by USERPRINCIPALNAME() in Power BI Desktop by selecting "Test As" from the Security section of Modelling tab - and entering any target email.
Since you are connecting to a shared dataset - these options are disabled. Given this limitation - the only workaround may be reguarly publish the report to a test/dev PBI service environment online. I don't believe you can override USERPRINCIPALNAME() in PBI desktop when connecting to a shared dataset. - Anonymous6 years ago
Hi Anonymous,
Perhaps you can add RLS role to your data model to enable the UPN instead guid id string of user names.
For detailed descriptions, you can take a look at the following blog that told about similar issues(if it helps for your scenario) :
Using Username() in DAX with Row-Level Security
Regards,Xiaoxin Sheng
Anonymous
You can typically override the result returned by USERPRINCIPALNAME() in Power BI Desktop by selecting "Test As" from the Security section of Modelling tab - and entering any target email.
Since you are connecting to a shared dataset - these options are disabled. Given this limitation - the only workaround may be reguarly publish the report to a test/dev PBI service environment online. I don't believe you can override USERPRINCIPALNAME() in PBI desktop when connecting to a shared dataset.