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

Pivot table years

Hi ,

I am attaching the app and i need the values as it in mentioned with out hard !coding those values

1 Solution

Accepted Solutions
JonnyPoole
Employee
Employee

Give this example a try.

1. Simplified the SET ANALYSIS

2. used  before() function to grab the values from the TOTAL and DUAL PACK and subtract prior column(Year)

3. Dynamic to number of years (3 in this case but will work dynamically if there were more or less years)

Capture.PNG.png

View solution in original post

5 Replies
JonnyPoole
Employee
Employee

Give this example a try.

1. Simplified the SET ANALYSIS

2. used  before() function to grab the values from the TOTAL and DUAL PACK and subtract prior column(Year)

3. Dynamic to number of years (3 in this case but will work dynamically if there were more or less years)

Capture.PNG.png

Not applicable
Author

Hi Jonathan thanks for your reply it is working fine but a small concern if we have more data in 2012 also showing some values that should not beCapture.PNG.png

Not applicable
Author

the concern is

if we have 0's are no value in 2012 the values are showing in 2012 column

so how to remove the data if we have 0's are no data

JonnyPoole
Employee
Employee

I added an IF expression to check if its the first column (first YEAR). If it is, the DIFF calcs will show as blank.

I also updated the presentation tab to render nulls as blank rather than 0's.

Anonymous
Not applicable
Author

see attached.