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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
marama
Helper I
Helper I

Hide content based on username

Hi!
I want only specific users to be able to see the content of the column, so I was hoping to be able to create a measure like this:

note_masked =
IF(USERPRINCIPALNAME()="xxx@xxx.xxx", 'table'[note] , "XXXX")

But it does not work, because it's a measure (hence aggregation). What would be the right approach here, how to achieve the goal?
1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @marama,

 

If you want to restrict specific end user to have access to specific columns, I suggest you to try OLS (preview) which could be configured in third party tool : Tabular Editor .

Object-level security (OLS) enables model authors to secure specific tables or columns from report viewers. 

For reference:

Announcing public preview of Object-Level Security in Power BI

Object Level Security In Power BI

Implementing Object-level Security in Power BI

 

Best Regards,
Rico Zhou

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

4 REPLIES 4
marama
Helper I
Helper I

I believe I've made it work by using 

FIRSTNONBLANK

@marama !
Hi, I do have similar problem like you had.

What was the measure finally looking like? Could you post it? Thx!

Anonymous
Not applicable

Hi @marama ,

 

I am so gald that you could solve your problem by yourself. Please kindly Accept your workaround as the solution. More people will benefit from it. Or you are still confused about it, please provide me with more details about your problem or share me with your pbix file without sensitive data.


Best Regards,

Rico Zhou

Anonymous
Not applicable

Hi @marama,

 

If you want to restrict specific end user to have access to specific columns, I suggest you to try OLS (preview) which could be configured in third party tool : Tabular Editor .

Object-level security (OLS) enables model authors to secure specific tables or columns from report viewers. 

For reference:

Announcing public preview of Object-Level Security in Power BI

Object Level Security In Power BI

Implementing Object-level Security in Power BI

 

Best Regards,
Rico Zhou

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.