Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
sundarakumar
Specialist II
Specialist II

Set analysis help

Hi All,

I have data quarter wise, now I want to display the last quarter's values.

my dimension is year. so when I use {<quarter=$(max(=(quarter))>} an not getting any value for 2014 since there is no q4 data for 2014. I have only q1 data for 2014. so I want the chart to show q4 data for all years other than 2014 and q1 data for 2014,. my requirement is always show the max quarter data at any time. Please help me with the set analysis expression for this scenario.

I know this can be done with

if(year=max(year),

     if quarter=4 set analysis to Q4 and 3 2 1 so on only for max year

and rest with set analysis max quarter. But I think this can be done in set analysis itself.

Thanks in advance

-Sundar

2 Replies
vikasmahajan

Hii,

Find attachment of master calendar Please link it with your transaction data and

give following expression

SUM({$<FiscalYear={$(=max(FiscalYear))}>} [ Sales Amount])

Hope this help you.

Vikas

Hope this resolve your issue.
If the issue is solved please mark the answer with Accept as Solution & like it.
If you want to go quickly, go alone. If you want to go far, go together.
jagan
Luminary Alumni
Luminary Alumni

Hi,

Try like this

=Sum(Aggr(If(Quarter = Max(TOTAL <Year> Quarter), Sum(Sales), 0), Year, Quarter))

or

Sum(Aggr(Sum({<quarter= {'$(=max(quarter))'}>} , Year))

Hope this helps you.

Regards,

Jagan.