Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
soniasweety
Master
Master

On Open trigger

Hi All,

i want to see when i open the document it should be selected with current quarter and next 3 quarters.

Hi tresesco‌     in this  thread  its  for previous quarter to next 3  . Future Data

now if i want form current quarter to next 3 quarters  how can i modify the expression?

='=Rank( if(Quarter>=Year(Today())&''Q''&Ceil(Month(Today())/3), -(Left(Quarter,4)*10+Right(Quarter,1))))<5'

exact output should be :  2018Q4,2019Q1,2019Q2,2019Q3

current quarter is 2018Q4.

1 Solution

Accepted Solutions
Frank_Hartmann
Master II
Master II

8 Replies
Frank_Hartmann
Master II
Master II

see attached

soniasweety
Master
Master
Author

thank you it worked.  but can you explain how 10 and 11 works here?

soniasweety
Master
Master
Author

one more question -  is this dynamic?

it means if current quarter is 2019Q1  

it will automatically select  2019Q1 2019Q2 2019Q3 2019Q4  ?

Frank_Hartmann
Master II
Master II

i was just playing with the expression and this is what worked for me. but im not sure if this is correct and dynamic. have to investigate

soniasweety
Master
Master
Author

ohh ... if it is not dynamic it will be problem for me again

Hi tresesco   can we have your inputs please ....

Frank_Hartmann
Master II
Master II

see attached file.

for me it works dynamically.

But one thing i dont understand. You mentioned that current quarter is Q4 but now we are in Q3.

But anyway If you open up the qvw it will show from next quarter.

If you set your computertime to e.g. Jan18  and quit QlikView, open it again and start the qvw it will show Q2-18, Q3-18,Q4-18, Q1-19

Frank_Hartmann
Master II
Master II

Just invastigated your posted qvw and the only thing you will have to change is the red part :

='=Rank( if(Quarter>Year(Today())&''Q''&Ceil(Month(Today())/3), -(Left(Quarter,4)*10+Right(Quarter,1))))<5'


This already works dynamically!



soniasweety
Master
Master
Author

yes it will work dynamically.. as we are not hard coded any quarter values  . thanks for  information