Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
Sign up nowGet Fabric certified for FREE! Don't miss your chance! Learn more
Hello everyone,
I'm facing an issue with the use of Username() or UserPrincipalName() in a report
I have to build a report to allow my ressources to track the projects on which they are assigned, I cannot used RLS due to the need of this ressources to see more details on other reports using the same dataset
If I use the following measure:
The ID in the ressources table, is the project ID, so my table ressource contains this kind of information
| ID Project | ResourceMail |
| 1 | ResourceA@microsoft.com |
| 2 | ResourceA@microsoft.com |
| 2 | ResourceB@microsoft.com |
| 2 | ResourceC@microsoft.com |
| 3 | ResourceB@microsoft.com |
| 3 | ResourceC@microsoft.com |
Solved! Go to Solution.
Try this measure
ProjectResourceVisibility =
VAR CurrentUser = USERPRINCIPALNAME()
RETURN
IF(
CALCULATE(
COUNTROWS(Ressources),
FILTER(Ressources, Ressources[ResourceMail] = CurrentUser)
) > 0,
1,
0
)
Try this measure
ProjectResourceVisibility =
VAR CurrentUser = USERPRINCIPALNAME()
RETURN
IF(
CALCULATE(
COUNTROWS(Ressources),
FILTER(Ressources, Ressources[ResourceMail] = CurrentUser)
) > 0,
1,
0
)
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 63 | |
| 62 | |
| 42 | |
| 19 | |
| 16 |
| User | Count |
|---|---|
| 118 | |
| 106 | |
| 38 | |
| 28 | |
| 27 |