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

A new Data Days event is coming soon! This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. Don't miss out.

Reply
Anonymous
Not applicable

Filtering table per USERNAME()

Hi 

 

Not knowing DAX at all but know excel so struggling to learn how things are done, 

 

I have a table with many users data and wish to filter it per user, 

 

I have a table user mapping that has the email addesses [Username] and names [Name]

i've created a measure that returns the username from their loggin

 

Userfilter =
LOOKUPVALUE(Usermapping[Name],Usermapping[Username],USERNAME())
 
This works fine and i can have a card that returns the name of the user, 
 
But how can i filter a column on based on this measure 
 
I tried a new column with
User List =
IF('PDM Output'[Assignee]=Usermapping[Userfilter],'PDM Output'[Assignee],BLANK())
 
But it errors with the username function is not supported, seems like a real simple problem but hard to solve in power bi, please help

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

I've solved it by using the the roles and permissions that only shows the usernames that are the same as USERNAME(), Usernames is only used in the one table that i want to filter so all other data is ok

View solution in original post

3 REPLIES 3
Anonymous
Not applicable

Thanks could you make that a bit simplier for me i'm a bit fried on this at the moment, The User filter returns at the moment a single value but in the 'PDM Output'[Assignee] column i have returns many rows of the user, can't see how i can do this without creating a column that is linked to the Username to flag it as 0 or 1 

 

Greg_Deckler
Community Champion
Community Champion

@Anonymous Correct, USERNAME is not supported in calculated columns but rather only in measures. So, use a measure instead that returns a 1 or 0 and in your Filters pane filter the measure to only be 1 or 0. The Complex Selector - Microsoft Power BI Community



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...
Anonymous
Not applicable

I've solved it by using the the roles and permissions that only shows the usernames that are the same as USERNAME(), Usernames is only used in the one table that i want to filter so all other data is ok

Helpful resources

Announcements
May Power BI Update Carousel

Power BI Monthly Update - May 2026

Check out the May 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.