Forum Discussion
lcasey
9 years agoPost Prodigy
Why wont the same formula work?
Hello, I have a table I created called countries, it is a simple formula. Countries = Distinct('Transactions'[COUNTRY]) This works perfect--No issues and yes there are multiple AND duplic...
- Anonymous9 years ago
You could do it in Power Query with something like this:
let Source = Transactions, KeptOnlyCountryAndRegion = Table.SelectColumns(Source,{"Country", "Region"}), RemovedBlankCountries = Table.SelectRows(KeptOnlyCountryAndRegion, each [Country] <> ""), RemovedDuplicateCountryandRegions = Table.Distinct(RemovedBlankCountries) in RemovedDuplicateCountryandRegions
Anonymous
9 years agoNot applicable
It's because you're not creating a new table there. According to your screenshot, you're creating a new column in an existing table (Countries). That's a table formula, not a column formula.
- lcasey9 years agoPost Prodigy
Thanks, That does make sense now, I need to enter a Single formula to get Countries and Regions.
- Anonymous9 years agoNot applicable
You could do it in Power Query with something like this:
let Source = Transactions, KeptOnlyCountryAndRegion = Table.SelectColumns(Source,{"Country", "Region"}), RemovedBlankCountries = Table.SelectRows(KeptOnlyCountryAndRegion, each [Country] <> ""), RemovedDuplicateCountryandRegions = Table.Distinct(RemovedBlankCountries) in RemovedDuplicateCountryandRegions