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!Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.
Table 1- Name = ‘AADUsers’
UserPrincipalName | DisplayName |
User One | |
User Two | |
User Three | |
User Five |
Table 2 – Name = ‘InScope’
UserPrincipalName | DisplayName |
User One | |
User Five | |
User Ten |
I’d like to make a column on Table 1 (AADUsers) that is boulean Yes/No field if the ‘UserPrincipalName’ exists in table 2 (InScope)
Like this: -
Table 1 – ‘AADUsers’
UserPrincipalName | DisplayName | IsInScope |
User One | Yes | |
User Two | No | |
User Three | No | |
User Five | Yes |
Can anyone assist with the DAX expression for this?
Solved! Go to Solution.
HI, @davidtoyne
just adjust tablename and column name
try below for column code
Column =
var a = LOOKUPVALUE(U2[user name],U2[user name],U1[username])
RETURN
IF(a<>BLANK(),"yes","no")
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi, @davidtoyne
@Dangar332 gives a solution that you can try to use, and below there is a different solution you can refer to it as well
New Column:
IsInScope =
IF (
COUNTROWS (
FILTER ( InScope, InScope[UserPrincipal] = AADUsers[UserPrincipal] )
) > 0,
"Yes",
"No"
)
Best Regards,
Yang
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data in the Power BI Forum
Hi, @davidtoyne
@Dangar332 gives a solution that you can try to use, and below there is a different solution you can refer to it as well
New Column:
IsInScope =
IF (
COUNTROWS (
FILTER ( InScope, InScope[UserPrincipal] = AADUsers[UserPrincipal] )
) > 0,
"Yes",
"No"
)
Best Regards,
Yang
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
How to get your questions answered quickly -- How to provide sample data in the Power BI Forum
HI, @davidtoyne
just adjust tablename and column name
try below for column code
Column =
var a = LOOKUPVALUE(U2[user name],U2[user name],U1[username])
RETURN
IF(a<>BLANK(),"yes","no")
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the September 2025 Power BI update to learn about new features.