Forum Discussion
Shelley
7 years agoPost Prodigy
How to lookup values in another table in the Query Editor?
Does anyone know if/how this can be done? I have a table in the Query Editor that has a number of fields, one of which is the Customer #. I want to make a new column in this table that contains R...
- 7 years ago
Hi Shelley,
Please check out the demo in the attachment. It's a solution in Power Query (the Custom column).
(let currentCustomer = [CustomerName] in Table.SelectRows(Table1, each [CustomerName] = currentCustomer)){0}[CustomerID]Best Regards,
Dale
PowerBIUser9901
6 years agoAdvocate II
Thank you so much! This has helped me greatly. Can you please explain the logic in this power query custom column ( such as what does the "{0}" do in the query?). Also, how does this compare to using Power Query Merge?
Doodle
5 years agoAdvocate II
I am wondering the same thing.
Specifically, since we can either use the custom lookup or the merge to achieve the desired result...would like to know which one is better in terms of efficiency and performance.
Can anyone provide some insight? Thank you for your help!