Skip to main content
Microsoft Idea

Power BI

Needs Votes

Option to Use PBI Credentials for UserName () /UserPrincipalName ()

Vote (4) Share
Ben's profile image

Ben on 06 Sep 2019 01:28:02

Power BI Desktop computes the values to use DAX functions UserName () and UserPrincipalName () based on the *local computer's* currently logged in user, not the user logged in to Desktop.

It would be really neat if Power BI Desktop offered the option (perhaps a checkbox under settings) for UserName () and UserPrincipalName () to be populated based on account used to log into Power BI Desktop. After all, if I’m logged in to Desktop under a certain account, I’m probably going to be uploading to Service under that account, and so it’s quite likely that any RLS testing (or other use of UserName () /UserPrincipalName () ) I’d want to do would be relative to that account.

Comments (1)
Ben's profile image Profile Picture

Randy Coates on 06 Jul 2020 00:03:41

RE: Option to Use PBI Credentials for UserName () /UserPrincipalName ()

In fact, expand this idea to allow a USERPRINCIPALNAME () value to be entered during the "view as role" functionality that is already provided, with a default of current user. As a developer, especially with imported data, I can see all data, so there is no security risk. Maybe other connection types such as Live or Power BI dataset with RLS would need to block this ability.