Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
alamn2
Contributor
Contributor

Help in populating previous period value in pivot table where current value is zero

I have a pivot table with certain measures by month , the values i have a only for certain months and i want to replicate the previous value if the current value is zero. i need to achieve this on the front 

below is the current view of the qlik pivot table 

Field A Field B Field C Field D Field E Field F Field G Month Apr-21 May-21 Jun-21 Jul-21 Aug-21
Company1             Measure 1 12.34 0.00 0.00 15.31 0.00
            Measure 2 12.34 0.00 0.00 15.31 0.00
            Measure 3 9.83 0.00 0.00 13.05 0.00
            Measure 4 9.83 - - 13.05 -
            Measure 5 802 0 0 804 0
            Measure 6 838 0 0 840 0
            Measure 7 838 0 0 840 0
Componnet 1 Area 1 location 1 date1 A value b Value Measure 1 9.17 0.00 0.00 12.48 0.00
Measure 2 9.17 0.00 0.00 12.48 0.00
Measure 3 14.53 0.00 0.00 17.35 0.00
Measure 4 14.53 - - 17.35 -
Measure 5 402 0 0 404 0
Measure 6 420 0 0 422 0
Measure 7 420 0 0 422 0
Date 2 A value b Value Measure 1 9.17 0.00 0.00 12.48 0.00
Measure 2 9.17 0.00 0.00 12.48 0.00
Measure 3 14.53 0.00 0.00 17.35 0.00
Measure 4 14.53 - - 17.35 -
Measure 5 402 0 0 404 0
Measure 6 420 0 0 422 0
Measure 7 420 0 0 422 0

and i would like to do the below in this case may , jun and jul to take apil value as they 0 and Aug to take July value as Aug is zero:

Field A Field B Field C Field D Field E Field F Field G Month Apr-21 May-21 Jun-21 Jul-21 Aug-21
Company1             Measure 1 12.34 12.34 12.34 15.31 15.31
            Measure 2 12.34 12.34 12.34 15.31 15.31
            Measure 3 9.83 9.83 9.83 13.05 13.05
            Measure 4 9.83 9.83 9.83 13.05 13.05
            Measure 5 802 802 802 804 804
            Measure 6 838 838 838 840 840
            Measure 7 838 838 838 840 840
Componnet 1 Area 1 location 1 date1 A value b Value Measure 1 9.17 9.17 9.17 12.48 12.48
Measure 2 9.17 9.17 9.17 12.48 12.48
Measure 3 14.53 14.53 14.53 17.35 17.35
Measure 4 14.53 14.53 14.53 17.35 17.35
Measure 5 402 402 402 404 404
Measure 6 420 420 420 422 422
Measure 7 420 420 420 422 422
Date 2 A value b Value Measure 1 9.17 9.17 9.17 12.48 12.48
Measure 2 9.17 9.17 9.17 12.48 12.48
Measure 3 14.53 14.53 14.53 17.35 17.35
Measure 4 14.53 14.53 14.53 17.35 17.35
Measure 5 402 402 402 404 404
Measure 6 420 420 420 422 422
Measure 7 420 420 420 422 422

below is one of my existing formulas  for measure 1:

sum(if(some_Date=anotherDate,NUM(Measure1,'0.00;(0.00)'))),

 

can i have some help in modifying that formula to achieve what i want in the front end ?

 

 

 

Labels (3)
0 Replies