Step-by-step: User-based sorting

edited December 2023 in Blog

Author: David Edwards is a Certified Master Anaplanner and Principal at Columbus Consulting.

While there is sufficient documentation regarding how the user list can be an effective tool for UX filtering and dynamic cell access, there is also the opportunity to leverage users when designing custom sorting functionality within UX cards.

A common request among users is the ability to sort a grid or chart in a customizable manner, often combining multiple columns and criteria. Anaplan native functionality allows for sorting a dataset based on values within a single column either ascending or descending. This is viable for quick sorting but often falls short of meeting the demands of a user base with diverse analysis and reporting needs.

In this tutorial, multiple fields will be combined into one unique sorting line item that leverages the users list for customizable sorting specific to each user’s needs.

Step 1: Determine which fields are valid for sorting

This involves polling your user group to compile a list of line items that should be included in the eventual final sort line item. This can be accomplished in multiple ways, even as simply as sending out a mass email to collect opinions. Basically, do not assume that you understand your users’ needs without explicitly asking them!

Step 2: Add a list that includes all options from Step 1

Once feedback is collected from the user group, add a list that captures which line items are required for sorting. This will be used in a later step to allow users to select how criteria should be prioritized in the final sort line item.

Step 3: Add sorting line items for each criteria in the reporting module

In the reporting module, add text-formatted line items for each required sorting criteria. This should match both the user poll and sorting list from steps 1 and 2.

Step 4: Add a user-based input module for sorting selections

Add a module that is dimensioned by the users list and line items that match the sorting criteria. These line items should mimic the number of sorting options that the users have reported in the opinion polling from Step 1. In this example, we have four line items eligible for sorting.

Step 5: Set the sorting line item Applies To

In the reporting module, change the Applies To settings for the sorting line items to include the module’s existing dimensionality along with the users list.

Step 6: Write the sorting formulas

Each formula should include logic that assesses whether the line item should be included in the sort. This is accomplished by referencing the user input module from Step 4 as shown below.

Step 7: Combine each sorting criteria line item into one final sorting line item

Write a simple concatenation formula that combines each sorting criteria. This line item will be used on the UX page for grid formatting.

Step 8: Set the Show All Users option to Off

This is arguably the most important step. Without this setting, the reporting module will not properly reference the corresponding user selections in the input module and apply those to the UX grid. More information on this feature can be found in Anapedia.

Step 9: Apply the sort in the UX grid and publish changes

Navigate to the card settings of the UX grid. First, make sure that the sort line item is visible, then apply the preferred direction (i.e. ascending vs. descending). Once the sort is applied, hide the sort line item from the final page view. The sorting settings will be retained even though the line item is hidden.

Even though the final sort line item appears blank due to conflicting Applies To settings in the underlying module, Anaplan will apply the sort accordingly based on whichever user is viewing the page.

Summary and opportunities for further Anaplan functionality

This article provides an overview of customizable user-based sorting within a UX grid that goes beyond existing Anaplan functionality.

While there is nothing currently in the Anaplan product release timeline that addresses page sorting, customizable sorting could be enhanced through the following suggestions. Please consider adding your vote to get these features prioritized in future product releases:

  • Ability to sort a grid on a hidden line item: Idea Exchange link
  • Enhanced sorting that allows for Excel-like options (i.e. multiple line items in one sort, multiple directions for different sorting criteria): Idea Exchange link

Please comment if you have any suggestions to make sorting more robust on UX pages, or if you have examples of using similar functionality in your implementations.

Thanks for reading!