Qlik Community

QlikView Creating Analytics

Discussion Board for collaboration related to Creating Analytics for QlikView.

ramya_beginner
Contributor

Creating a sort order

Hi

I have a dimension in the table with the following calculated expression, I am getting the values from 2 different columns., how do I specify the sort order for the values ?

I want sort order to be as below :

'Uptime',

'Escapes / Mo'

P0 and P1 in Production'

'FCI Top 50'

=if(match(Category,'Escapes / Mo','P0 and P1 in Production'),Category,
if(match([User Friendly Metric Name],'Uptime','FCI Top 50'),[User Friendly Metric Name]))

Thanks!

1 Solution

Accepted Solutions
MVP
MVP

Re: Creating a sort order

If the list is static, then you can do a dummy load in the script to set the sort order:

Dummy:

LOAD * Inline

[

  Category

  Uptime

  Escapes / Mo

  P0 and P1 in Production

  FCI Top 50

];

... existing load that includes Category ...

DROP Table Dummy;

QV remembers the field sort order from the first load containing the field. Set the sort order to LOAD order.

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
7 Replies
MVP
MVP

Re: Creating a sort order

Maybe try a sort by expression with expression

=Match( if(match(Category,'Escapes / Mo','P0 and P1 in Production'),Category,
if(match([User Friendly Metric Name],'Uptime','FCI Top 50'),[User Friendly Metric Name])),

'Uptime',

'Escapes / Mo',

P0 and P1 in Production',

'FCI Top 50'

)

ramya_beginner
Contributor

Re: Creating a sort order

Thank you .. how do I avoid sort by state .. I mean I don't want the selected value to be top of the table .. I don't see that option to disable ..

Re: Creating a sort order

I this pivot table we are talking about?

sasikanth
Valued Contributor III

Re: Creating a sort order

try some thing like

wildmatch( only{1} if(match(Category,'Escapes / Mo','P0 and P1 in Production'),Category,
if(match([User Friendly Metric Name],'Uptime','FCI Top 50'),[User Friendly Metric Name])),

'Uptime',

'Escapes / Mo',

P0 and P1 in Production',

'FCI Top 50'

)

if the scroll bar is enabled in any object say List box then by default qlikview moves the selection to top.

sujeetsingh
Honored Contributor III

Re: Creating a sort order

Why not to define a sort order in backend and just calling it in your sort expression at UI.

MVP
MVP

Re: Creating a sort order

If the list is static, then you can do a dummy load in the script to set the sort order:

Dummy:

LOAD * Inline

[

  Category

  Uptime

  Escapes / Mo

  P0 and P1 in Production

  FCI Top 50

];

... existing load that includes Category ...

DROP Table Dummy;

QV remembers the field sort order from the first load containing the field. Set the sort order to LOAD order.

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
vsudhakar
Contributor III

Re: Creating a sort order

in sort tab have the to sort the according to the asc or desc

Community Browser