0
0
Power BIbi_tool~20 mins

FILTER function in Power BI - Practice Problems & Coding Challenges

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
FILTER Function Mastery
Get all challenges correct to earn this badge!
Test your skills under time pressure!
dax_lod_result
intermediate
2:00remaining
FILTER function with simple condition
Given the table Sales with columns Product and Quantity, what is the result of this DAX expression?
FILTER(Sales, Sales[Quantity] > 10)
AReturns all rows where Quantity is greater than 10
BReturns all rows where Quantity is less than or equal to 10
CReturns a single value of Quantity greater than 10
DReturns an error because FILTER needs a measure
Attempts:
2 left
💡 Hint
FILTER returns a table with rows matching the condition.
visualization
intermediate
2:00remaining
Using FILTER in a measure for visualization
You want to create a card visualization showing total sales for products with sales greater than 100 units. Which DAX measure using FILTER is correct?
ATotalSalesFiltered = SUM(FILTER(Sales, Sales[Quantity] > 100)[Amount])
BTotalSalesFiltered = CALCULATE(SUM(Sales[Amount]), FILTER(Sales, Sales[Quantity] > 100))
CTotalSalesFiltered = FILTER(Sales, SUM(Sales[Quantity]) > 100)
DTotalSalesFiltered = CALCULATE(FILTER(Sales, Sales[Quantity] > 100), SUM(Sales[Amount]))
Attempts:
2 left
💡 Hint
Use CALCULATE with FILTER to modify filter context.
data_modeling
advanced
2:00remaining
FILTER function with related tables
You have two tables: Orders and Customers, related by CustomerID. You want to filter Orders for customers in the 'USA'. Which DAX FILTER expression is correct?
AFILTER(Orders, Orders[Country] = "USA")
BFILTER(Orders, Customers[Country] = "USA")
CFILTER(Orders, RELATED(Customers[Country]) = "USA")
DFILTER(Customers, Customers[Country] = "USA")
Attempts:
2 left
💡 Hint
Use RELATED to access columns from related tables in FILTER.
🔧 Formula Fix
advanced
2:00remaining
Identify the error in this FILTER expression
What error will this DAX expression cause?
FILTER(Sales, Sales[Quantity] > 10 && Sales[Date])
AType error because Sales[Date] is not a boolean
BNo error, returns filtered table
CRuntime error due to missing aggregation
DSyntax error due to invalid logical condition
Attempts:
2 left
💡 Hint
Check the condition inside FILTER carefully.
🧠 Conceptual
expert
2:00remaining
FILTER function behavior with empty tables
If FILTER is applied on an empty table, what is the result?
AReturns an empty table
BReturns a table with one row containing blanks
CReturns an error because table is empty
DReturns the original table unfiltered
Attempts:
2 left
💡 Hint
Think about how FILTER works on no rows.