Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
jlakehivewyre
Contributor III
Contributor III

Yesterday Variable

I recently had to migrate from QlikCloud to QlikSense Business - I had an app that worked just fine, but there are various things not working when I exported/imported the App into the new QlikSense Business.

I have a variable set, that is for Yesterday; =Date(max({1}[Day]) ,'MM/DD/YYYY')

The output is correct, and it shows yesterday's date as 12/09/2019

In another table, I have some syntax to show sum of Revenue for Yesterday.  This worked fine as:

sum({<[Day]='$(vYesterday)'>} [Revenue (USD)])

But this just returns $0.00 value.  Not a dash, but actual $0.00; when it should be around $18K

Any ideas?

4 Replies
andoryuu
Creator III
Creator III

Try this with the additional curly brackets:
sum({<[Day]={'$(vYesterday)'}>} [Revenue (USD)])
dplr-rn
Partner - Master III
Partner - Master III

try this

sum({<[Day]={'$(vYesterday)'}>} [Revenue (USD)])

jlakehivewyre
Contributor III
Contributor III
Author

Thanks Andoryuu,

That didn't change anything.  It's just strange, it works as-is in my existing QlikCloud App; but not in the QlikSense Business version.  

dwforest
Specialist II
Specialist II

Make sure your standard date format at the top of the script is also 'MM/DD/YYYY'

Note that the default of Sum() will return 0, not null if all elements summed are null.