KNOWLEDGE BASE

After Upgrading a Top N Filter shows Different Results


Published: 05 Sep 2018
Last Modified Date: 27 Dec 2018

Issue

After upgrading a workbook from 10.5 to 2018.1, then the results in a top N filter may be different.

Environment

  • Tableau Desktop 10.5
  • Tableau Server 10.5

Resolution

Option 1: Replace the top N filter with a RANK() calculation

When filtering the view with a RANK() calculation on values 1-N, then Tableau will show all ties.

Option 2: Add another metric to determine how ties should be broken

For example, if several customers have the same exact sales item, then create a calculated field that sums sales and quantity. Create a top N filter on this calculated field rather than on sales.

Cause

When there are ties, then Tableau Desktop or Tableau Server randomly determines the order. In each version, Tableau is choosing a different order for the tied ranks, and thus a different set of top N are showing.

Additional Information

Using a top N filter that randomly filters out some items with a tied rank can be deceptive, because the view assumes the filtered out items are less in some way. Showing all ties, or adding a tie breaker are more robust methods.
Did this article resolve the issue?