Skip to main content
Announcements
Customer Spotlight: Discover what’s possible with embedded analytics Oct. 16 at 10:00 AM ET: REGISTER NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
vishavb007
Partner - Contributor III
Partner - Contributor III

Load Data by using Rest API

Hi All,

I am loading data from Elastic Search by using Rest API in Qlik Sense SaaS. I am able to get only 2 lac records from Elastic Search instance but there are 2 crore records are available in the ES. I have seen many solution to load all the data, none of that is working. The use of scroll API might work but I don't know how to use scroll API to get data from ES. I don't have ready reference script of scroll API. The pagination which I am trying in connection string is offset where I am able to load data only 2 lac records.

Pls, help me out to get all the records from ES to Qlik Sense.

Warm Regards,

Vishav Bhatia

M/W: +919034572560

 

6 Replies
Vinay_B
Support
Support

Hi @vishavb007 

I believe the first step for us is to know how the REST API being connected to handles paging, and it is really important to know where and how the API endpoints send the signal to get the next page. Also, Just to add some context, Qlik SaaS itself does pagination. Please refer to the image that I am attaching here.

 

If this resolves your query, please click on "Accept as Solution" for confirmation. Thanks!
vishavb007
Partner - Contributor III
Partner - Contributor III
Author

Hi @Vinay_B 

 

Sure, I am also using the Pagination supports by Qlik SaaS in connection string but here itself the limit to load the records is 2 lac.

I am using pagination type as offset as Elastic Search supports offset pagination.

Pls find attached image for your reference.

vishavb007_0-1634017371247.png

vishavb007_1-1634017401899.png

It is working for up to 2 lac records but for more than 2 lac records qlik is suggesting to use scroll API, pls refer below image.

vishavb007_2-1634017894925.png

 

Vinay_B
Support
Support

@vishavb007 I will check in my environment and update you on my findings. Thanks!

If this resolves your query, please click on "Accept as Solution" for confirmation. Thanks!
Akshesh_Patel
Support
Support

@vishavb007 

 Yes, you have to use the scroll API.

 

 https://www.elastic.co/guide/en/elasticsearch/reference/7.5/search-request-body.html#request-body-s...

After each post to the .../_search/scroll endpoint, you need to check if you received any data so you can stop when you've retrieved all the data.

Best

Akki

 

 

vishavb007
Partner - Contributor III
Partner - Contributor III
Author

Hi Akki,

 

Can you please share the Qlik load editor script for the same as it will help me to understand it more effectively.

 

Regards,

Vishav Bhatia

+919034572560

Saurabh_manish
Contributor
Contributor

Hi Vishav

I am facing issue Qlik rest connector for elasticsearch using custom pagination. Currently I am able to fetch only 10 records.

Thanks

Saurabh