+ Start a Discussion
JoannaJoanna 

Limit to number of records retrieved by SOQL query?

I have an s-control that retrieves opportunities, displays them in a listing, and allows for filtering and sorting.  However, I noticed that only 200 opportunities display, even if the filter criteria should pull more than 200 records.  Is there some kind of record limit imposed on SOQL queries?

I am using
sforceClient.init("{!API.Session_ID}","{!API.Partner_Server_URL_100}");
and
var queryResult = sforceClient.Query(SearchString);

queryResult.records.length never comes back as more than 200.

Does anyone have clarification for this?

Thanks,

Joanna
Ron HessRon Hess
It looks like you are using the old beta toolkit, you should switch to the supported version of this toolkit, the documentation is found here
http://www.salesforce.com/us/developer/docs/ajax/index.htm

in this document you can read about the process of getting all your records using query() and queryMore()

yes, you must perform multiple queries to get all records for a large query.

This document shows you how to port your scontrol to the new tookit.
http://www.salesforce.com/us/developer/docs/ajaxpre/Content/sforce_api_ajax_beta.htm