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: 
Not applicable

QlikView Quarter Filter

Hello Everyone,


I need some help regarding a quarter selection in my qvw file.


In my file, there are two filters (Year and Quarter) available.
Please have a look at the below two screenshots.
The Requirement is, if I select Year (e.g 2015) and Quarter(Q1), then my chart should show latest 8 quarters. But currently the chart is showing all the 12 quarters which are as follows:



But the Chart Dimension is not a Date Column (e.g 2015Q1, 2014Q4).

What should be the expression? currently this expression is used: sum(Proj__Default_Crp).


Looking forward to the correct answer.


Regards,

Sajid.

1 Solution

Accepted Solutions
jagan
Partner - Champion III
Partner - Champion III

Hi,

You need to bring date field from Year and Quarter in script, after that it would be easier to handle this

Data:

LOAD

*,

MakeDate(Year, Right(Quarter, 1) * 3) AS Date

FROM DataSource;

Now in set analysis use this expressions

=sum({<Year=, Quarter=, Date={'>=$(=QuarterStart(Max(Date), -7))<=$(=QuarterEnd(Max(Date)))'}>}Proj__Default_Crp)

Hope this helps you.

Regards,

Jagan

View solution in original post

1 Reply
jagan
Partner - Champion III
Partner - Champion III

Hi,

You need to bring date field from Year and Quarter in script, after that it would be easier to handle this

Data:

LOAD

*,

MakeDate(Year, Right(Quarter, 1) * 3) AS Date

FROM DataSource;

Now in set analysis use this expressions

=sum({<Year=, Quarter=, Date={'>=$(=QuarterStart(Max(Date), -7))<=$(=QuarterEnd(Max(Date)))'}>}Proj__Default_Crp)

Hope this helps you.

Regards,

Jagan