Forum Discussion
Anonymous
5 years agoNot applicable
Mcode:Error result If Look Up Value doesnt exist at Source table (should show as blank not "Error")
I have a table that looks up a value from another table namely LookUp table and Review table. I have below MCode in my custom column in Review table. = (let currentLookUp = [UniqueValue] in Table...
- Anonymous5 years ago
Hi Anonymous
It takes time to scan so many rows while using Table.SelectRows, please try Table.Group suggested by CNENFRNL edhans
you need to put the code offered by CNENFRNL after your currentLookUp = [UniqueValue] like this and paste in the custom column
=let currentLookUp = [UniqueValue] in Table.Group("LookUp", "UniqueValueCol", {"Grouped", each _}){[UniqueValue=currentLookUp]}?[Grouped]?{0}?[CategoryValue]?
Anonymous
5 years agoNot applicable
Hi Anonymous
have a try
= let
currentLookUp = [UniqueValue],
a = Table.SelectRows("LookUp", each [UniqueValueCol] = currentLookUp){0}?,
b= if a = null then "" else a[CategoryValue]
in
b
Anonymous
5 years agoNot applicable
hi Anonymous , got the same result in my previous formula thanks! However it takes a while to load right after clicking close and load from power query. I wonder If there is a way to make it much more faster its like 50 rows per minute and I have 35,000 rows.