Forum Discussion
Match ID from another table
Hi,
I have two tables, that are connected with an ID coloumn.
In the master table, I want a measure (or coloumn) that contains the information if the ID can be found in the other table.
So in table "Master" I have the following:
ID Name
1 John
2 Peter
3 Alex
4 George
And in table "Activity" I have the following:
ID
1
3
So in table "Master" I want a measure or additional coloum that contains Yes/No based on if the ID has been found in table "Activity".
I hope it makes sense.
Thanks in advance.
I believe master table is the one side
You can use this column in master table
Calculated Column = IF ( ISBLANK ( COUNTROWS ( RELATEDTABLE ( Activity ) ) ), "Not Found", "Found" )
Hi letsdothis
You may try to use below measure.
Measure =
IF ( MAX ( Master[ID] ) IN VALUES ( Activity[ID] ), "Yes", "No" )Regards,
Cherie
3 Replies
- Zubair_MuhammadCommunity Champion
I believe master table is the one side
You can use this column in master table
Calculated Column = IF ( ISBLANK ( COUNTROWS ( RELATEDTABLE ( Activity ) ) ), "Not Found", "Found" )
- erikajain02Resolver I
Hi,
First Create a new column :
Output = SUMX(RELATEDTABLE(Activity), Activity[Id1]) This will create a field in master table picking values from Activity table.
Then Create another column :
Flag = if( [Output]=Master[Id],1,0)
- v-cherch-msftMicrosoft Employee
Hi letsdothis
You may try to use below measure.
Measure =
IF ( MAX ( Master[ID] ) IN VALUES ( Activity[ID] ), "Yes", "No" )Regards,
Cherie