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

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
michael_maeuser
Partner Ambassador
Partner Ambassador

sum(if... problem

Hello, I´m trying to create an expression that shows the values for the last reload date... I´ve been trying this: sum(if(Date=date(reloadtime()), Liq)). It seems to be wrong. I don´t want to work with today() cause there are no values if the script has not been executed today. Any idea? Thanks in advance! Michael

1 Solution

Accepted Solutions
vijay_iitkgp
Partner - Specialist
Partner - Specialist

Can you use Sum(If(Date=Date(Makedate(Year(Reloadtime()),Month(Reloadtime()),Day(Reloadtime())),Liq))

View solution in original post

5 Replies
vijay_iitkgp
Partner - Specialist
Partner - Specialist

Hi,

It looks like formating error of date.

Please use sum(if(Date(Date,'DD-MM-YYYY')=Date(Reloadtime(),'DD-MM-YYYY'),Liq)). Hope this will work.

michael_maeuser
Partner Ambassador
Partner Ambassador
Author

unfortunately it doesn´t work either. i still get 0 as result. but if i make sum(if(Date=Today(), Liq)) i get the correct result (I executed the script today)

CELAMBARASAN
Partner - Champion
Partner - Champion

Hi,

     Can you check the format of date field whether it is in timestamp or normal date?

Celambarasan

vijay_iitkgp
Partner - Specialist
Partner - Specialist

Can you use Sum(If(Date=Date(Makedate(Year(Reloadtime()),Month(Reloadtime()),Day(Reloadtime())),Liq))

michael_maeuser
Partner Ambassador
Partner Ambassador
Author

thanks so much!!