Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Level up your Power BI skills this month - build one visual each week and tell better stories with data! Get started

Reply
Anonymous
Not applicable

Username() not giving any value in Power BI Desktop/Service

Hi All,

I am very new to Power BI and trying to understand how RLS works. In the process, as a first step I am trying to get the username() value in the report, but it does not bring any value.

I created a measure and used it as below:

1.PNG

Can someone please help me out as to why it is showing blank.

Thanks

Poojitha

 

 

1 ACCEPTED SOLUTION

HI

Both funcion username and userpricipalname works when you place them in Table or card
If u just drag them to raport dosnt work (default is chart )

Desktop

obraz.png

Serwice

obraz.png

View solution in original post

7 REPLIES 7
AndreyLitovc
New Member

was anyone able to resolve this? encountered the same issue and no other method works

v-eachen-msft
Community Support
Community Support

Hi @Anonymous ,

 

Which type of account are you logged into Windows? Is it a guest account?

 

Community Support Team _ Eads
If this post helps, then please consider Accept it as the solution to help the other members find it.
wzkoral
Advocate II
Advocate II

Anonymous
Not applicable

I followed the same steps but I still dont see any value.

HI

Both funcion username and userpricipalname works when you place them in Table or card
If u just drag them to raport dosnt work (default is chart )

Desktop

obraz.png

Serwice

obraz.png

Anonymous
Not applicable

From memory its because you are in the Power BI desktop and you aren't connected by a username.  Try publishing your report into your "My Workspace" and testing this again.  You'll likely find it will work there.

Anonymous
Not applicable

I published to Service and I still cannot see the username field. 

Helpful resources

Announcements
April Power BI Update Carousel

Power BI Monthly Update - April 2026

Check out the April 2026 Power BI update to learn about new features.

Fabric SQL PBI Data Days

Data Days 2026 coming soon!

Sign up to receive a private message when registration opens and key events begin.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.