Forum Discussion
Select specific column in a table based on filter from static unrelated table
Hi All,
Please see below diagram for detail :
Requirement : My requirement is when I select code name in the static table , the product_name with code gets displayed in the table.
GIVEN : I have static table with list of codes and code name.
I have a table with product_key and product_name in different codes
These 2 tables are not linked.
WHEN : When I choose filter on code name like below "Italy" the highlighted value should appear in Product Name Table.
Please help me to achieve this in Power BI.
I am really stuck here and looking for possible alternatives.
Thanks in advance.
Hi alexa_0028 ,
You can create this measure:
Switch =SWITCH(TRUE(),SELECTEDVALUE('Static Table'[Code Name])="Italy",SELECTEDVALUE('Product Name Table'[Product_Name_IT]),SELECTEDVALUE('Static Table'[Code Name])="Spanish",SELECTEDVALUE('Product Name Table'[Product_Name_ES]),SELECTEDVALUE('Static Table'[Code Name])="German",SELECTEDVALUE('Product Name Table'[Product_Name_G]),SELECTEDVALUE('Static Table'[Code Name])="English",SELECTEDVALUE('Product Name Table'[Product_Name_EN]))Result:Jori
If I answered your question, please mark it as a solution to help other members find it more quickly.
2 Replies
- jppv20
Solution Sage
Hi alexa_0028 ,
You can create this measure:
Switch =SWITCH(TRUE(),SELECTEDVALUE('Static Table'[Code Name])="Italy",SELECTEDVALUE('Product Name Table'[Product_Name_IT]),SELECTEDVALUE('Static Table'[Code Name])="Spanish",SELECTEDVALUE('Product Name Table'[Product_Name_ES]),SELECTEDVALUE('Static Table'[Code Name])="German",SELECTEDVALUE('Product Name Table'[Product_Name_G]),SELECTEDVALUE('Static Table'[Code Name])="English",SELECTEDVALUE('Product Name Table'[Product_Name_EN]))Result:Jori
If I answered your question, please mark it as a solution to help other members find it more quickly.
- alexa_0028
Resolver II
Hi jppv20
Thank you so much for your quick reply.
This solution worked like a charm for me. A big Kudos to you.
Thank you so much again !!