Bird
0
0

What will be the output of this Power Query M code?

medium📝 dax lod result Q5 of 15
Power BI - Data Cleaning with Power Query
What will be the output of this Power Query M code?
Table.Distinct(#"Sales Data", {"OrderID"})

Assuming the Sales Data table has 200 rows with 150 unique OrderIDs.
AA table with 200 rows
BA table with 150 rows, duplicates removed by OrderID
CA table with 50 rows
DAn error because syntax is wrong
Step-by-Step Solution
Solution:
  1. Step 1: Understand Table.Distinct function

    Table.Distinct removes duplicate rows based on specified columns, here OrderID.
  2. Step 2: Apply to data

    Since there are 150 unique OrderIDs, the resulting table will have 150 rows.
  3. Final Answer:

    Table with 150 rows, duplicates removed by OrderID -> Option B
  4. Quick Check:

    Table.Distinct removes duplicates by column(s) [OK]
Quick Trick: Table.Distinct removes duplicates by given columns [OK]
Common Mistakes:
  • Assuming no rows are removed
  • Thinking it returns an error
  • Confusing number of unique rows

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Power BI Quizzes