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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
powerbinoob457
Frequent Visitor

If a row out of many contains a value return value in another table

I've got a a bunch of users who are assigned corporate phones.

Some users ony have 1 phone while others have multiples.

The date is organized in two tables one containing the asset information and one containing user information as below

 

UserPhone Typeserial
user 1Iphone0
user 1Android1
user 2Iphone2
user 2Iphone3
user 3Iphone4
User 4Android5

and

Useremail address
user 1email
user 2email
user 3email
user 4email

User is unique in this table.

I need to create a calculated column in the second that that will identify all IOS users as such

UserPhone TypeUses IOS
user 1emailYes
user 2emailYes
user 3emailYes
user 4emailNo

 

Thanks

1 ACCEPTED SOLUTION
Zubair_Muhammad
Community Champion
Community Champion

HI @powerbinoob457

 

You can use this Column in Table 2 assuming Tables are linked via User Column

 

Column =
IF (
    CONTAINS ( RELATEDTABLE ( Table1 ), Table1[Phone Type], "IPhone" ),
    "Yes",
    "No"
)

Regards
Zubair

Please try my custom visuals

View solution in original post

2 REPLIES 2
Zubair_Muhammad
Community Champion
Community Champion

HI @powerbinoob457

 

You can use this Column in Table 2 assuming Tables are linked via User Column

 

Column =
IF (
    CONTAINS ( RELATEDTABLE ( Table1 ), Table1[Phone Type], "IPhone" ),
    "Yes",
    "No"
)

Regards
Zubair

Please try my custom visuals

@powerbinoob457

 

Please see the attached file

 

contains1.png


Regards
Zubair

Please try my custom visuals

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.