Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
giomartini1
Contributor
Contributor

Cannot load by if condition - The error occurred here: LOOP

Hello everyone,

I'm trying to load some qvds based on specific hours and until now I don't have success. I'm already thinking it's a bug. I'm assuming this because when I copied this same script and put in a new App, it works. So I don't understand why this happens but it's annoying just think that I may need to create a new app to fix this.

We're using Qlik Sense Feb 2022 patch 6.
 
"The control statement is not correctly matched with its corresponding start statement
The error occurred here:
LOOP"
erro_qs_data_prep_ifstatement_2.jpg
 
Same script in another app:
su_qs_data_prep_ifstatement_2.jpg

  


 

Script:

IF HOUR(NOW()) > 4 AND HOUR(NOW()) < 12 THEN

Fato:
LOAD * FROM [$(vSmartTransformations)/Ebao/Fato/Fato.qvd] (qvd);

END IF

IF HOUR(NOW()) >= 12 AND HOUR(NOW()) < 19 THEN

Fato:
LOAD * FROM [$(vSmartTransformations)/SunDB/GM_SunDB_FINAL_Cocorretagem.qvd](qvd);

ELSE

T:LOAD * INLINE [
A,
1
];

END IF

EXIT SCRIPT;

Thanks,
Giovanni
Labels (1)
11 Replies
giomartini1
Contributor
Contributor
Author

Unfortunately as any tip you gave didn't work until now, last week I opened a case with Qlik to see further in that. Thanks for the help so far. When I've a return I let you all know.

giomartini1
Contributor
Contributor
Author

Hello everyone,

Just a short update, Qlik is working in this topic as a Bug issue.