Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Q&A with Qlik - Qlik Cloud Migration: Questions about migrating to Qlik Cloud? Catch the latest replay!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

hi i am here

i have a category and am calculating mar and apr total sales month over month sale in mar and apr values tell me the expression

Labels (1)
5 Replies
Anonymous
Not applicable
Author

hey give some example your input and expected output.

Thanks

BKC

Not applicable
Author

Sum( {$<Date_Num={">$(=(MTDStartDate))<=$(=(MTDEndDate))"}>}  Amount))

MTDStartDate and MTDEndDate Variables

MTDStartDate==num(max(addmonths(Date,-1)))

MTDEndDate==num(Max(Date))


Not applicable
Author

Try like below,

=sum({<monthfield={'mar','apr'}>}sales)

Not applicable
Author

i am creating variable and vYear,vCurrentMonth,vPreviousMonth and i am pick for straight table dimention is Category

and expression is what ....i dont no

my expression is ---->  sum({<year={$(vCurrentMonth)}>}sales)

                         -----> sum({<year={$(vPreviousMonth)}>}sales) this expression is right or wrong it's wrong tell me this answer

Anonymous
Not applicable
Author

your expression syntax is correct.

But you want to sum of both the month sale (current + previous)

So you need to write -

sum({<year={$(vCurrentMonth)}>}sales) + sum({<year={$(vPreviousMonth)}>}sales)

Current month sale =10

Prev month sale = 20

then you will get 30

Thanks

BKC