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: 
nareshthavidishetty
Creator III
Creator III

month on moth sales calculation

hi im new to qlikview

im struck with following expression

month on month sales,year on year sales comparison

1 Solution

Accepted Solutions
maxgro
MVP
MVP


you can start adding some useful fields (ie in a master calendar) to your doc

     d,                                                         // date

     year(d) as y,                                         // year

     year(d)*12 + month(d) as mserial            // month serial

then with set analysis (v = sales)

sum({$ <y={$(=max(y))}>} v)                              // sales max year

sum({$ <y={$(=max(y)-1)}>} v)                           // previous

sum({$ <mserial={$(=max(mserial))}>} v)            // sales max month

sum({$ <mserial={$(=max(mserial)-1)}>} v)         // previous

or you can post your qlik doc (.qvw) here

View solution in original post

3 Replies
krishna_2644
Specialist III
Specialist III

Hi Naresh,

could you please be more specific as what exactly your scenario is? and what exactly you are looking for.

Thanks

maxgro
MVP
MVP


you can start adding some useful fields (ie in a master calendar) to your doc

     d,                                                         // date

     year(d) as y,                                         // year

     year(d)*12 + month(d) as mserial            // month serial

then with set analysis (v = sales)

sum({$ <y={$(=max(y))}>} v)                              // sales max year

sum({$ <y={$(=max(y)-1)}>} v)                           // previous

sum({$ <mserial={$(=max(mserial))}>} v)            // sales max month

sum({$ <mserial={$(=max(mserial)-1)}>} v)         // previous

or you can post your qlik doc (.qvw) here

nareshthavidishetty
Creator III
Creator III
Author

thanks