Forum Discussion
olimilo
Post Prodigy
7 years agoTrying to create a filtered list from another table
I'm trying to create a column with a list of holidays (l_Holidays) for my main table (Source) using an existing Holiday table. But upon checking, it always returns an empty list (which should not be the case). Anyone know what I'm doing wrong here? The holiday list returned should be the holidays for that country.
= Table.AddColumn(
Source,
"l_Holidays",
each Table.Column(Table.SelectRows(Holiday, each Holiday[Country] = [Country]),
"Date")
)Hello olimilo
I created a small example to test.
Seemingly it works
Please check the attached Excel file
4 Replies
- Zubair_Muhammad
Community Champion
try this modification
= Table.AddColumn( Source, "l_Holidays", each let mycountry=[Country] in Table.Column(Table.SelectRows(Holiday, each [Country] = mycountry), "Date") )- olimilo
Post Prodigy
Hi Zubair_Muhammad ,
I tried your edit and am still getting blank lists for each row. Do you know what could be the problem here?
- Zubair_Muhammad
Community Champion
Hello olimilo
I created a small example to test.
Seemingly it works
Please check the attached Excel file