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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

IF statement Coordinated between 2 Table

Hi Guys,

 

I don't know if its possible but i want to Create an IF statement but coordinated with 2 Table.

 

Image below for clarity.

 

I have 6 Tables All of them have the Same first name but different Role/Labour Category.

iyogj_1-1642121129168.png

 

Employee List table have the Labour category which i want to Put into the Level1-5 Role column.

 

iyogj_2-1642121678945.png

 

as far my Program line as below which is not working. 

 

if Employeelist[First name] = Level1[First Name] then Employeelist[Labour Category] = Level1[Role] else Level1[Role] = null

 

Hoping you could help me again.

 

thank you.

 

Cheers,

 

 

 

1 ACCEPTED SOLUTION
AllisonKennedy
Super User
Super User

@Anonymous  Why do you need 6 tables? can this all be in one table?

 

I would suggest you start with the Employee table, then from the Home tab > Merge Queries. Select the Level 1 table, pick the First Name columns in both tables, click Ok.

You'll now have a new column, click the two arrows next to the column heading for this new column and select all the columns you want included from the Level1 table. 


Please @mention me in your reply if you want a response.

Copying DAX from this post? Click here for a hack to quickly replace it with your own table names

Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C

I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com

View solution in original post

3 REPLIES 3
AllisonKennedy
Super User
Super User

@Anonymous  Why do you need 6 tables? can this all be in one table?

 

I would suggest you start with the Employee table, then from the Home tab > Merge Queries. Select the Level 1 table, pick the First Name columns in both tables, click Ok.

You'll now have a new column, click the two arrows next to the column heading for this new column and select all the columns you want included from the Level1 table. 


Please @mention me in your reply if you want a response.

Copying DAX from this post? Click here for a hack to quickly replace it with your own table names

Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C

I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com

Anonymous
Not applicable

Hi @AllisonKennedy ,

 

Thank you for your response.

The Employeelist Table is manually added by different people and the Levels are automatically added from HR software. that's why they are in the different table.

 

i tried your solution it works but vice versa but the idea is the same. Really thank you. apologies if the solution is so simple enough i am very new to PowerBI. 

 

Cheers,

@Anonymous  no need to apologize, that's what learning and this forum is for. Glad it's working!


Please @mention me in your reply if you want a response.

Copying DAX from this post? Click here for a hack to quickly replace it with your own table names

Has this post solved your problem? Please Accept as Solution so that others can find it quickly and to let the community know your problem has been solved.
If you found this post helpful, please give Kudos C

I work as a Microsoft trainer and consultant, specialising in Power BI and Power Query.
www.excelwithallison.com

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.