Newer Version Available
Step 6: Query Jobs
-
Create the job.
URI
Example of creating a bulk query job
The response includes the job id and shows the job’s state as UploadComplete. (You use the job id to monitor the job or get its results.)
Example response body
-
Monitor the job’s state using the returned job id.
URI
Example of monitoring the state of the query job
Example response body
The response shows the current state of the job. Repeat this step until the state is JobComplete.
-
Get the results of the job.
URI
Example of getting the results of the job
The response shows the results of the SOQL query when you created the query job.
Example response body
This example returns a small result set, and it’s easy to see the complete results. Queries that return larger results spread them across a sequence of result sets. To see the other result sets, use the locator to fetch the next set of results. For more information, see Get Results for a Query Job.