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

Exit script on day's specified in qvd

Hi,

My reload script is scheduled to run every workday. But it must not run on certain day's. These day's are specified in a qvd.

I've the feeling that I should use the exist() function, but I don't know how to solve this.

1 Solution

Accepted Solutions
Erik6
Contributor
Contributor
Author

I've found a solution:

Holidays:

LOAD
HolidayYear,
Concat(HolidayDate,',') as ListOfHolidays
FROM (qvd)
Where
HolidayYear =Year(Today())
Group By HolidayYear;

LET vCheck= Peek('ListOfHolidays',0,'Holidays');
LET vToday=Today()+0;  //the +0 converts the date into a datenumber, quick/dirty.
DROP Table Holidays;

If Wildmatch($(vToday),$(vCheck))<>0 then
EXIT SCRIPT;
ELSE
//do your coding
ENDIF

View solution in original post

1 Reply
Erik6
Contributor
Contributor
Author

I've found a solution:

Holidays:

LOAD
HolidayYear,
Concat(HolidayDate,',') as ListOfHolidays
FROM (qvd)
Where
HolidayYear =Year(Today())
Group By HolidayYear;

LET vCheck= Peek('ListOfHolidays',0,'Holidays');
LET vToday=Today()+0;  //the +0 converts the date into a datenumber, quick/dirty.
DROP Table Holidays;

If Wildmatch($(vToday),$(vCheck))<>0 then
EXIT SCRIPT;
ELSE
//do your coding
ENDIF