Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in NYC Sept 4th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
CHL
Contributor
Contributor

Chart Sort Order Weekday & Time

Hi All,

I have a chart which is aggregating averages (this part works as expected). Although I need this to be over Weekday and Hour. My Dimension for that is:

 

(WEEKDAY([Time of Complete.Date])&' '& Interval( (HOUR([Time of Complete])) / 24 , 'hh:mm'))

 

 But I cannot get this to sort in any logical order.

Can I get this to work via an expression?

Thanks!

Labels (1)
1 Reply
Or
MVP
MVP

You could use a Dual() to get this dimension to sort correctly - currently, the sort will be based on alphabetical sorting since you've created a string (by concatenating the whitespace). Should be something like:

Dual(

(WEEKDAY([Time of Complete.Date])&' '& Interval( (HOUR([Time of Complete])) / 24 , 'hh:mm')),

num(WEEKDAY([Time of Complete.Date])) + (HOUR([Time of Complete]) / 24)

)