Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Calculate Difference column

Hello,

Next example

First column year with totals pro week for years 2014 and 2013

2014                       2013

52 100                    150

51 200                     200

50 300                    600

49 400                    350

Now i want to add 2 columns pro year.

First column shows me the difference amount. Column next to it shows me the percentage growth / lost toward previous year.

2014                                  2013

52 100   -50     33,33%        150

51 200   +0            0%        200

50 300   -300         -50%      600

49 400   +50          14%       350

How to do this?

10 Replies
sushil353
Master II
Master II

Hi,

Find attached.

HTH

sushil

Not applicable
Author

Hi,


Can't find attachment

Not applicable
Author

Attention to Orginal Question

Who helps me?
Thx in forward.

Not applicable
Author

Hello,

Big Challenge. Does nobody knows the answer?

Not applicable
Author

Attached is the solution

Ivelin

Not applicable
Author

Thx, but excuses me I am new.

I do not know what you mean. can you explain me more?

Thx in advance

Not applicable
Author

Hello,

Who can help me and explain how attaced is being used?

suresh_rawat
Creator II
Creator II

Hi,

I will Explain You abou the attached file above.

1 ) For Getting 2013 Sales the expression is : Sum({<Year = {'2013'}>} totals)

2 ) For Getting 2014 Sales the expression is :Sum({<Year = {'2014'}>} totals)

Then you Want 3 Expression in the Difference

3 ) Add Expression and Name it Difference : Sum({<Year = {'2014'}>} totals) - Sum({<Year = {'2013'}>} totals) - Use this Expression.

Then you Want 4 Expression in the Difference in Percentage

Use This Expression : (Sum({<Year = {'2014'}>} totals) - Sum({<Year = {'2013'}>} totals))/ Sum({<Year = {'2013'}>} totals)

Hope you understand this.

Regards

Suresh Rawat

Not applicable
Author

thx! But instead of Year i have to take yearweeknr?! I shall try this later.