Activity Forums Salesforce® Discussions How does query() API call count against my daily limit?

  • Abhinav

    Member
    May 27, 2016 at 1:29 pm

    Hi Himanshu,

    Every time the request is properly handled by the server, one API call is consumed. Specifically, in regards to queries, there's two functions, named query and queryMore. Every call to query and queryMore counts as one API call. So, the more records you return, the more times you'll have to call queryMore, and the more API calls you'll consume.

    As you may know, query and queryMore are limited by a Batch Size, which means that the API consumption of a query is a function of how many results are returned and the Batch Size of that result set.

    The cost complexity of the query (including sub-queries and other relationship queries) are not cost factors, although in exchange for this freedom, we do have limitations on what we can query so that the query cost has an upper limit on how many resources are used by the salesforce.com servers.

    For example, there's limits on query complexity, and some special per-object limits. You can read more about those limits in SOQL and SOSL Limits. Fortunately, we have several tools available to us.

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos