Skip to main content
Announcements
SYSTEM MAINTENANCE: Thurs., Sept. 19, 1 AM ET, Platform will be unavailable for approx. 60 minutes.
cancel
Showing results for 
Search instead for 
Did you mean: 
deep2021
Creator III
Creator III

Rest API - Error handling in qlik

Hi All,

I am fetching data from rest API.

for the parameters where the data is missing, it shows the below error.


The following error occurred:
The remote server returned an error: (404) Not Found.
The error occurred here:

 

Table:

SQL SELECT

*

 FROM CSV "_response_header" PK "__KEY__response_header"
WITH CONNECTION (URL "$(vAPI_Link)",
HTTPHEADER "accept" "text/csv",
HTTPHEADER "Authorization" "Bearer $(vToken)"
)

;

 

Can you please suggest how should I go ahead?

Thanks

Labels (3)
4 Replies
Mathumitha
Partner - Contributor III
Partner - Contributor III

Hi,

Have you tried testing the connection in postman? And, also you can try to create the connections using REST connection in Data connections panel. 

 

Mathumitha_0-1677067378440.png

 

neerajthakur
Creator III
Creator III

First check the format of data passed in variable.

Check whether connection is open by using telnet there may be some port issue, if you are able to use other API of same server check API whether it is working elsewhere. Sometimes server may be down.

Thanks & Regards,
Please Accepts as Solution if it solves your query.
deep2021
Creator III
Creator III
Author

Hi,

I am able to fetch the data successfully, only for few dates when data is not available it is showing the above  error. I want to ignore the above error for these dates.

Can you please suggest on this?

Thanks

henrikalmen
Specialist
Specialist

If you want to ignore errors and just continue, do this:

set ErrorMode=0;
//[load/select and so on here, all errors will be ignored]
set ErrorMode=1; //restore ErrorMode to normal state so that errors after this line will abort reload as usual