function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
mgaljanicmgaljanic 

Problem with salesforce API 250 rows returned

Hi all,

I am using salesforce api to pull data through a created connected app that was created through Build>Create>Apps.

 

On the other side (my custom application), looks like I am getting only 250 records where there should be much more. I have looked through most of documentation, but was unable to find place to regulate amount of rows returned per call.

 

Do you have any advice on where can I start to look for an answer?

Thank you,

Mario

Best Answer chosen by Admin (Salesforce Developers) 
vbsvbs
For every query call Salesforce returns data in blocks of limited records. This is inherent due to multi-tenant setup and not restricted to API's but internally within the application too. What you will need is a use the querymore API call passing in the queryLocator from the original query call. This will get the data to your in batches. See the implementation here that should help you.
http://developer.force.com/cookbook/recipe/implementing-the-query-querymore-pattern

Please be sure to mark this as a solution so that others find this useful.