Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Pivot table - need expression in one column

Hello,

Can you help me figure out a way to display  the % change in only the last column rather than every column. The user will select the YR_Qtr range they want to see so this is dynamic.

There are two expressions for this Pivot Table: #1 Sum(Cases) and #2 (sum(Cases) - rangesum (before(Sum(Cases))))/rangesum (before(Sum(Cases))))

I just want to show the percent change for the last two quarters that the user selects in any given range. Thanks!

YR _Qtr2011Q12011Q22011Q32011Q4
FacilityCases%ChangeCases%ChangeCases%ChangeCases%Change
Hospital A64939-666982.71%61052-8.47%653036.96%
Hospital B17044-171440.59%17082-0.36%16317-4.48%
Hospital C12867-12506-2.81%129173.29%12526-3.03%
Hospital D13947-13750-1.41%143164.12%14253-0.44%
Hospital E45832-43175-5.80%42334-1.95%439793.89%
1 Reply
swuehl
MVP
MVP

I don't think it's possible to hide expression columns for certain horizontal dimension values (you can probably set the outcome to not showing results, but that would still leave some empty columns).

But you can try using a total (i.e. partial sum in pivot tables) column, checking for the total columns using secondarydimensionality() in your expression and applying a special expression to only consider previous two columns for your % change.