Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Calculated Dimension for YearQTR

Hi All-hope someone can help me on this.I have a dimension called 'current YrQtr' which returns value 2012Q3 for Nov.I need a calculated dimension which should return current qtr along with three previous qtrs.

Final result should be

2012Q3,2012Q2,2012Q1 and 2011Q4.

Thanks-pooja

3 Replies
MayilVahanan

Hi

Due to have date field? if so,

Try like this

=sum({<Date = {'>=$(=Monthstart(AddMonths(today(),-12)))<=$(=Today())'}>}Sales)

Calculate last 12 month from today..

Hope it helps

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
Not applicable
Author

Thanks for your reply.Objective is to have a calculated dimension that can dispaly 4 qtrs(current qtr and 3 previous qtrs).I am not worried about expression.

QTR.png

MayilVahanan

HI

Use current YrQtr as dimension and then use the above epression. if you have datefield..

Can you post a sample file/

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.