Can you group by one column in a Table visual and sort on a completely different column?

Currently we have several partner groups that I am aggregating data together for and would prefer to structure the visual so all the partners could use the same one…this would also help since there is a limitation of how many total visuals can be included on a page.

Hi @lhamilton,

I’m not sure if I understood your question correctly but open the dropdown menu for the fields in your “Group by” field well, and go to Sort by > Sort options. You can select a different field in your dataset for sorting.

image

Hi @David_Wong,

I understand there is a sorting feature…that part is clear. I need the first column to in groups to where the list for Affiliate #1 is all together then sorted by implementation start date, then the list for Affiliate #2 is all together…

If I use the group by then the visual will not show line level detail and will simply summarize the totals for each affiliate. Does that help to clarify what I am trying to solve for?

Thanks,
Lauren

Hello @lhamilton, my apologies for the delayed response. I’m not sure if you are still facing this issue or not but the solution I came up with was creating a denseRank calculated field. The QuickSight documentation for the function is here.

The function would look like this:
denseRank([max({ImplementationStartDate}) DESC], [{Entity}])

That will be used to group your Entity field together while giving you the sort option you want on Start Date. Feel free to swap DESC for ASC if that is your preferred sort order. Then you can add the Sort By on your entity field to make sure they are grouped together.

Last, hide the denseRank calculated field from your visual display. This will ensure the sorting works as expected without it changing what columns are shown in your visual.