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: 
Not applicable

Dates.

Hi All,

I have the following script that sets up my variables:

Let vCurrYear=year(today());

Let vCurrMonth=month(today());

Let vCurrDay= (I want this variable to be set to the previous day in date format)

Let vPrevYear=Year(AddYears(today(), -1));

Let vPrevMonth=Month(AddMonths(today(),-1));

Let vPrevDay=(I want this variable to be set to the vCurrentDay-1 day in date format)

Please help,

1 Solution

Accepted Solutions
crusader_
Partner - Specialist
Partner - Specialist

Hi

Try this

Let vCurrDay= date(today()-1)

and

Let vPrevDay = date(today()-2)


Hope this helps.

Andrei

View solution in original post

3 Replies
crusader_
Partner - Specialist
Partner - Specialist

Hi

Try this

Let vCurrDay= date(today()-1)

and

Let vPrevDay = date(today()-2)


Hope this helps.

Andrei

Not applicable
Author

ok so thats sets up the variables great, but the my set analysis doesn't

Sum({1<call_date = {$(vCurrDay)}>} calls_offered)

crusader_
Partner - Specialist
Partner - Specialist

Hi,

Please check variable value and your call_date in text object.

And ensure that call_date has a date format.

HTH

Andrei