This field is required.
Only these extensions are allowed(.jpg, .JPG, .jpeg, .JPEG, .gif, .GIF, .png, .PNG)
Tags cannot contain the characters ' /, \\, #, ?, or ; >,< '
Only these extensions are allowed(.zip,.ZIP,.pdf,.PDF,.qvf,.QVF,.qvw,.QVW)
Discussion Board for collaboration related to QlikView App Development.
I want a field year and sales. I want to create a new field accumulatesales which should be sum of current year sales + previous year sales.
How to create this new field in the script?
Please provide your suggestions.
sum(sales) as sales,
from ****YOUR SOURCE**;
sum(sales) +Previous(sales) as New_Sales
order by year asc;
it depends on your data
this could be a solution
load * inline [
load Year, Sales + Previous(Sales) as TwoYearSales Resident z order by Year;
if(IsNull(Sales + Previous(Sales)),Sales,(Sales + Previous(Sales))) as PreviousSales
Resident z Order by Year;