Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi, Anyone can help out deduct based on accumulate value minus previous month accumulate value as new field as screenshot below
Expected result also as per screenshot.
Hopefully it can done in edit script part.
Thank you.
Here is script solution
Sales:
LOAD ID,
AccumSales,
Date
FROM
QlikCommunityFile.xlsx
(ooxml, embedded labels, table is Sheet1);
New:
NoConcatenate
LOAD *,
if(rowno()=1 or ID<>Previous(ID),Peek(AccumSales,(RowNo()-1)-1)-AccumSales,Null()) as MonthlySales
Resident Sales
Order by ID desc ;
DROP Table Sales;
May be like attached qvw.
If the sorting of ID doesn't matter, you can try this expression:
=Above(TOTAL AccumSales) - AccumSales
Alternatively, if you have QV12, you can try this:
=Aggr(Above(TOTAL AccumSales) - AccumSales, (ID, (NUMERIC, desc)), Date)
Here is script solution
Sales:
LOAD ID,
AccumSales,
Date
FROM
QlikCommunityFile.xlsx
(ooxml, embedded labels, table is Sheet1);
New:
NoConcatenate
LOAD *,
if(rowno()=1 or ID<>Previous(ID),Peek(AccumSales,(RowNo()-1)-1)-AccumSales,Null()) as MonthlySales
Resident Sales
Order by ID desc ;
DROP Table Sales;
Nice colors ! Celebrating Holi in India ?
Yeah. It's holi. Festival of colors.
Thanks!