# How to find percent change between two years

Hello sir, i am new to qlik view,

I have 4 years sales data(2008,2009,2010,2011). i need to find out %change of sales from 2009, 2010,2011. Assume that i have fields "paymentYear", "salesAmount". i need 3 columns or rows containing year, salesamount, %change from YearToYear.

• ###### How to find percent change between two years

Hi,

You can use below expression for all the three columns.

CY = SUM({\$<paymentYear={"\$(=Max(paymentYear))"}>} salesAmount)

PY = SUM({\$<paymentYear={"\$(=Max(paymentYear)-1)"}>} salesAmount)

%Change = (CY-PY)/PY

CY=Current Year, PY=Previous Year

Hope this helps.

Please revert back for any further query.

Cheers,

Dhananjay (DJ)

• ###### Re: How to find percent change between two years

see the attached file

ex: for year 2009

% change= (2009 sales- 2008 sales/2008 sales)*100

• ###### How to find percent change between two years

Thank you sir it is working Fine.............

But,

I want to Use in single row. How can I apply this  formula" =((column(1)-above(column(1)))/above(column(1)))" Because i am using pivot table. when i chaged to row-wise. it is not calculating.

• ###### Re: How to find percent change between two years

Load data some thing like below

xxx:

year,sales

2008,10

2009,20

2010,30

2011,40

];

Data:

*,

(sales-Previous(sales))/Previous(sales) as Value

resident xxx;

Drop table xxx;

And use Year as expression Value and Sales as expressions

See the attached sample file and Solutions sheet.

HTH

Rgds

Anand

• ###### How to find percent change between two years

I need OutPut Like

2008 %change 2009 %change 2010 %change

sales          30000    ---       40000   15%    50000 12%

Regards