Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Not applicable

Issue in sort by expression in a table

Hi Experts

In a Qlik Sense dashboard, I need to sort a column of a table based on an expression. This column is not the first column of this table. E.g. I have City Name, Customer Name as two columns in the table. I need to sort City name alphabetically, but Customer names under a particular city based on sales (des) of that customer under that city. If I just add the sales expression in Customer name sort, then it is sorting it based on total sales of that customer across all cities, not just that city.

City NameCustomer NameSales
New YorkAlex100
New YorkBeth120
New YorkCharlie130

This is how its appearing. Under New York, though Alex has only 100, still appearing on top as total sales of Alex across cities is 250 which is more than sales of any other customer across cities.

If I add sales as another column and sort based on that, it works fine. If I add a column as City name&Customer name and add sort expression on this column, it works fine. But, I can't do this as I don't need Sales as a column or City&Customer as a column.

It seems, sort using an expression is calculation the expression just based on that column value disregarding the values in other dimensions of table.

How can I fix this issue? Please let me know if you need any other details to help me.

Thanks in advance.

Community Browser