Forum Discussion
Values based on condition from another table
- Anonymous3 years ago
Hi Ondrej ,
You can create a separate table with words in one column and assigned value in another column. Then, you can use the Merge Queries feature to join the two tables based on the word column. After that, you can use the Replace Values feature to replace the words in the main table with their corresponding numeric values.
Merge queries overview - Power Query | Microsoft Learn
Replace values and errors - Power Query | Microsoft Learn
Best Regards,
Stephen Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- 3 years ago
it turns out the solution is pretty simple
you just do not want to do it in power query editor, but using simple DAX expression, you can add a column in power bi data view tab
NameOfNewColumn = LOOKUPVALUE('SourceTab'[WantedValue],'SourceTab'[ValueToCompare],'ThisTab'[ValueToCompare])
Hi Ondrej ,
You can create a separate table with words in one column and assigned value in another column. Then, you can use the Merge Queries feature to join the two tables based on the word column. After that, you can use the Replace Values feature to replace the words in the main table with their corresponding numeric values.
Merge queries overview - Power Query | Microsoft Learn
Replace values and errors - Power Query | Microsoft Learn
Best Regards,
Stephen Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.