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: 
Eaun
Contributor III
Contributor III

Rolling Qty

How can I reproduce the formula in column J in this excel sheet to do a rolling Qty on the on hand qty in qlik sense on a pivot table ?


I've had no luck so far : (

1 Reply
Eaun
Contributor III
Contributor III
Author

Tried this :

Test:
LOAD
Rowno() as RowNumber,
PROCESS_CODE,
LINE_CODE,
PART_NUMBER,
CUSTOMER_P_O_NUMBER,
SHIPPING_DATE,
"ORDER QTY",
"SHIPPED QTY",
"REMAINING QTY TO SHIP",
"ON HAND QTY" as [On Hand Rolling Qty],
"ON HAND QTY"
FROM [lib://Qlik Test/Other source files/Rolling Qty.xlsx]
(ooxml, embedded labels, table is Rad2);

Left Join (Test)
Load Distinct
RowNumber,
if( alt(previous([On Hand Rolling Qty]),0)>=0,
alt(previous([On Hand Rolling Qty])-[REMAINING QTY TO SHIP],
alt(previous([On Hand Rolling Qty])-[SHIPPED QTY] ))) as [Rolling Qty]

Resident Test;

but the last row does not down date : ( 

Any ideas how I can get around this ?