Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi,
I am trying to implement dynamic row level security on my reports. I followed the entire instructions that has been provided in https://community.powerbi.com/t5/Community-Blog/Different-approach-to-Dynamic-Row-Level-Security/bc-... .
Also I tried performing following steps:
It still throws me error “ CUSTOMDATA, USERNAME and USERPRINCIPALNAME functions are not supported in calculated tables/columns. These functions may only be used in Measures or in the AllowedRowsExpression.”
Could anyone please provide me with a possible workaround for the error?
Thankyou In Advance
Hi @adharia,
Please notice the issue have been asked on the comments of the article you posted. The author said:
Username() function can't be used in calculated column. So you should rather put the final formula into role row level filter directly.
Paste this expression into role definition and it will work
NOT(ISBLANK(LOOKUPVALUE(security_mapping[CATEGORY],security_mapping[CATEGORY],[Category],security_mapping[USER],USERNAME())))When publishing to PowerBI.com
NOT(ISBLANK(LOOKUPVALUE(security_mapping[CATEGORY],security_mapping[CATEGORY],[Category],security_mappi
The solution is not effective to you? Please review the first and second comments, please post feedback when you have still other problem.
Best Regards,
Angelia
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 40 | |
| 37 | |
| 33 | |
| 29 | |
| 27 |
| User | Count |
|---|---|
| 133 | |
| 104 | |
| 61 | |
| 59 | |
| 55 |