Challenge - 5 Problems
Top N Filters Master
Get all challenges correct to earn this badge!
Test your skills under time pressure!
❓ dax_lod_result
intermediate2:00remaining
Calculate Top 3 Products by Sales
You have a dataset with Product Names and Sales Amounts. You want to create a Top N filter to show only the top 3 products by total sales. Which DAX expression correctly calculates the rank of each product to enable this filter?
Tableau
Rank = RANKX(ALL('Products'[Product Name]), CALCULATE(SUM('Sales'[Amount])), , DESC, DENSE)
Attempts:
2 left
💡 Hint
Use ALL to ignore filters and rank all products by total sales descending.
✗ Incorrect
Option B uses ALL to remove filters on Product Name and ranks products by total sales in descending order with dense ranking, which is correct for Top N filtering.
❓ visualization
intermediate2:00remaining
Best Practice for Top N Filter Visualization
You want to create a dashboard showing the Top 5 customers by revenue. Which visualization approach best follows best practices for Top N filters in Tableau?
Attempts:
2 left
💡 Hint
Interactive parameters with calculated fields help users dynamically select Top N.
✗ Incorrect
Option C uses a parameter and calculated field to dynamically filter and visualize the Top N customers, which is a best practice for usability and clarity.
❓ data_modeling
advanced2:00remaining
Handling Ties in Top N Filters
In a Top N filter scenario, some products have the same sales amount causing ties in ranking. Which approach ensures all tied products at the Nth position are included in the filter?
Attempts:
2 left
💡 Hint
Dense ranking assigns the same rank to ties and does not skip ranks.
✗ Incorrect
Dense ranking assigns the same rank to tied values and does not skip subsequent ranks, so filtering rank <= N includes all tied products at the Nth rank.
🔧 Formula Fix
advanced2:00remaining
Why Does This Top N Filter Show Incorrect Results?
You wrote this DAX measure to filter Top 10 customers by sales: Top10Customers = IF(RANKX(ALL('Customers'), SUM('Sales'[Amount])) <= 10, 1, 0). But the filter shows fewer than 10 customers. What is the most likely cause?
Tableau
Top10Customers = IF(RANKX(ALL('Customers'), SUM('Sales'[Amount])) <= 10, 1, 0)
Attempts:
2 left
💡 Hint
Check the order argument in RANKX to rank highest sales first.
✗ Incorrect
By default, RANKX ranks in ascending order, so the lowest sales get rank 1. Without specifying DESC, the top 10 customers by sales are not correctly identified.
🧠 Conceptual
expert3:00remaining
Impact of Context on Top N Filters
In Tableau, when applying a Top N filter on a dimension, how does the filter context affect the results if the filter is applied before or after aggregation? Choose the correct statement.
Attempts:
2 left
💡 Hint
Think about whether filtering raw data or aggregated results changes totals.
✗ Incorrect
Filtering before aggregation limits the data set early, which can exclude data needed for accurate totals. Filtering after aggregation preserves totals but may include unwanted data in detail.