Reputation: 147
Is there a way to return the data set if the value on one of the columns (Animal) appears more than once, within PowerQuery?
For example, this is the data set.
I want the outcome to be like this.
Is this possible? Basically if any count of animal is < 2, then it would not show up on the outcome.
Upvotes: 0
Views: 94
Reputation: 1204
Create a new step and use the following function:
= Table.SelectRows(YourSource, each Table.Contains(Table.SelectRows(Table.Group(YourSource, {"Animal"}, {{"Count", each Table.RowCount(_), Int64.Type}}), each ([Count] > 1)),_,{"Animal"}))
Remember to change the YourSource statements for your previous step name or source. Hope it helps.
Upvotes: 1