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

improper order of week numbers in filter pane

Hi guys,

I have data from last three months from 2018 (Ocober, November, December).

I am trying to sort numbers of weeks in proper order in filter pane. I have used the formula:

= match(week([Sale date]) ,
'40', '41', '42', '43', '44', '45', '46', '47', '48', '49', '50', '51', '52', '1') as last days of December come to 1st week.

The formula does not work as in filter pane start from 43rd week, then 40th and so on.  Still sorting by expression stays ascending - this I cannot remove.

Could you help me to get the proper order of the weeks as '40', '41', '42', '43', '44', '45', '46', '47', '48', '49', '50', '51', '52', '1' ?

Labels (2)
1 Solution

Accepted Solutions
JordyWegman
Partner - Master
Partner - Master

Hi Edyta,

What you need is a year week sequence number. This can be done if you make a calendar for your data.

Then you generate with RowNo() a unique number for each week and sort based on this week with your weeks as dimension.

Jordy

Climber

Work smarter, not harder

View solution in original post

2 Replies
JordyWegman
Partner - Master
Partner - Master

Hi Edyta,

What you need is a year week sequence number. This can be done if you make a calendar for your data.

Then you generate with RowNo() a unique number for each week and sort based on this week with your weeks as dimension.

Jordy

Climber

Work smarter, not harder
Edyta
Contributor III
Contributor III
Author

I'm quite new to Qlik.

Any prompts how to make week sequence number?