4 Replies Latest reply: Feb 23, 2017 2:25 AM by Jayaseelan K

# Compare current quarter year with previous quarter year

Hi Friends,

I have to compare same quarter year with previous year quarter year than I'm trying to Replace Sales example Q1 2016 sales is 4 with Q1 2015 sales 10 then i will get Q1 2016 as 10 similarly  all ,please help me to achieve this

Quarter Year ,Sales

Q1 2015, 10

Q2 2015,23

Q3 2015,20

Q4 2015,5

Q1 2016,4

Q2 2016,6

Q3 2016,10

Output :

Dimension as "Quarter Year" and expression sum (Sales) then output should be like

Quarter year ,Curr sales ,Presales

Q1 2015, 10,0

Q2 2015,23,0

Q3 2015,20,0

Q4 2015,5,0

Q1 2016,10

Q2 2016,23

Q3 2016,20

• ###### Re: Compare current quarter year with previous quarter year

Front end solution may be this?

Create object and use dimensions are [Quarter Year]

Expressions are

Curr Sales

Sum({<[Quarter Year] = {'\$(=Max([Quarter Year]))'}>}Sales)

Presales

Sum({<[Quarter Year] = {'\$(=Max([Quarter Year]-1))'}>}Sales)

• ###### Re: Compare current quarter year with previous quarter year

Hi Anil,

\$(=Max([Quarter Year])) this not work [Quarter Year] only when we have numeric also the value will get max Q3 2016,10

I have to get growth of sales  Q1 2016/Q1 2015 -1

so im trying to create a new column or any other solution let me know

• ###### Re: Compare current quarter year with previous quarter year

Q1 2016 is the Max year of first quarter and then Q1 2015 - 1  is that you meant is Last year of Max year and then it should be first quarter (Here what does -1) . Would you describe more please

• ###### Re: Compare current quarter year with previous quarter year

Hi Sunil,

I have got your desired output. I have done this on edit Script. Please find the attachment. i hope this will helps you.

Thanks,