Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
HI All,
Need to create current vs previous qurter..
For Example:
If I select 2016 Q1 then Output should be --- 2016 Q1 & 2015 Q4.
If I select 2015 Q3 then Output should be --- 2015 Q3 & 2015 Q2.
Kindly help me on this..
Regards,
Helen
Create a numeric quarter field, for example a date:
Dual( Year(MyDate) & 'Q' & Ceil(Month(MyDate)/3), QuarterStart(MyDate)) as MyQuarter
Then create two expressions:
Current Quarter: Sum(Amount)
Previous Quarter: Sum({<MyQuarter#={'$(=QuarterStart(Max(MyQuarter),-1))'}>}Amount)
And if it doesn't work please post a small qlikview document with some example data.
In your calendar, add Quarter sequence number - something like"
...
Year(Caldate) * 4 + Floor(Month(Caldate) / 4) As QSeq,
...
Now you can use a simple set expression:
Current quarter:
Sum({<QSeq = {"$(=Max(QSeq))"}>} Amount)
Previous quarter
Sum({<QSeq = {"$(=Max(QSeq)-1)"}>} Amount)
(replace CalDate with the date field in your calendar and adapt the above expression to your requirements)
attached the excel & app as above
Regards,
Helen
See attached example.
Thanks..
With out any selection also i need to See Current quarter & Previous Quarter
Regards,
Helen
Then make sure your data contains data from 2016. The document you posted doesn't.
Make it default current quarter & previous quarter..
Regards,
Helen
Based on the given data .Make it default current quarter & previous quarter..
Regards,
Helen
Can't. Current quarter is the first quarter of 2016. Your document does not contain data from 2016.