Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
hopkinsc
Partner - Specialist III
Partner - Specialist III

Sorting in a pivot table on 2 dimensions

Hi all,

I'm struggling to fins a solution to enable me to sort a pivot table correctly using the expression and 1 of the dimensions.

My pivot table has 2 dimension..

Site (as a column) and Month (which has been pivoted).

There is 1 expression. 

I want to sort it descending  on the expression but for a specific month. 

I have attached an example, in the example there are 3 months - Nov, Dec, Jan

I want to sort it using the expression and Dec. 

Can anyone help please? 

Thanks

3 Replies
hopkinsc
Partner - Specialist III
Partner - Specialist III
Author

Does anyone have any ideas on this please?

Aasir
Creator III
Creator III

Use a sorting like below.

if(Month = 'Dec', -YourExpression, 0)
 

hopkinsc
Partner - Specialist III
Partner - Specialist III
Author

Hi, thanks for the reply, I've already tried that but it doesn't work. I can't figure out what the sort it after applying that logic but its not what i need. 

hopkinsc_0-1705481623401.png

 

The sorting works in the Dec column until values appear in the Nov or Jan column then the sorting in the Dec column stops working. 

The values in Dec up until the nulls start are descending, then the 3 values after the 3 nulls are bigger than the values above the nulls, so these 3 values should be before the all of the values in the screenshot. 

Could this be a limitation in the pivot table object itself?