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

Get previous Month sales in straight table

Hi everyone,

I need some help to get the previous month sales (not using Above function) in a straight table, even in the case there were no sales.

For example I have the following table:

   

AccountIDYYYYMMYYYYMM_PrevSales
1232015012014126536
123201503201502800
1232015042015034743
123201510201509120
452201512201511790
5622014102014095464
5622015012014127808

I need to see for :

Account 123, YYYYMM 201501, Sales Previous Month would be 0    (for Dec 2014)

Account 123, YYYYMM 201503, Sales Previous Month would be 0     (for Feb 2015)

Account 123, YYYYMM 201504, Sales Previous Month would be 800      (for Mar 2015)

I tried something along the line of

=SUM( {<YYYYMM={"$(=YYYYMM_Prev)"} >} Sales )

but did not manage to make it work...

Can someone please help?

Application is attached

Thanks in advance!

Jon

2 Replies
Not applicable
Author

Not applicable
Author

Hello and thanks for the link you provided.

Seems like the AsOf Table is the best solution the problem I illustrated, even with the case of 'missing' dates in the data set as in my case.

I would very much appreciate if you can modifying my application to include the AsOf structure as I never seen it implemented?

Also since in my case, I need to do calculation for each AccountID?

Thanks!