Power QueryExercises

Filtering and sorting quiz

Row filters, null in conditions, multi-key sorting and top-N.

Revise first: Filter rows by value, Sort rows on more than one column, Keep the top N rows after sorting, Remove blank rows and keep an explicit row order

Question 1

1.How many rows does this keep?

Table.RowCount(Table.SelectRows(#table({"Region", "Qty"}, {{"North", 2}, {"South", null}, {"North", 5}, {"West", 1}}), each [Qty] >= 2))
Question 2

2.How many rows does this keep?

Table.RowCount(Table.SelectRows(#table({"Region", "Qty"}, {{"North", 2}, {"South", null}, {"North", 5}, {"West", 1}}), each [Qty] <> 1))
Question 3

3.Which sort gives Region A→Z and, within a region, highest Qty first?

Question 4

4.To get the three largest orders, what order of steps is right?

Question 5

5.Is "complete" = "Complete" in M?

Question 6

6.Why is "remove rows 3 to 5" a bad way to drop bad rows?

Question 7

7.What does this return?

Table.Sort(#table({"Region", "Qty"}, {{"North", 2}, {"South", null}, {"North", 5}, {"West", 1}}), {{"Qty", Order.Descending}}){0}[Region]
Question 8

8.Which conditions keep only rows from North or South that are also Complete?(select all that apply)

0 of 8 answered. Unanswered questions count as wrong.