---
schema_version: "1"
id: 91e81333370ac8b7128b76993c14dcaf61836637ca799158e4f4dce7801f1080
title: Get Information About a Query Job
collection: developer
version: current
locale: en-us
portal_url: https://docs.salesforce.com/developer/current/en-us/platform/api-asynch/guides/api-bulk-v2/bulk-query/query-get-one-job.md
canonical_url: https://developer.salesforce.com/docs/platform/api-asynch/guide/query-get-one-job.html
source_site: developer.salesforce.com
content_type: documentation
content_hash: c4f2f5cc668556edcd3f8538425052b95b6261028111ee68437b34244aab7e79
products:
  - Bulk API 2.0 and Bulk API Developer Guide
  - Platform Developer Content
---

# Get Information About a Query Job

Gets information about one query job.

## Syntax

**URI:** `/services/data/vXX.X/jobs/query/queryJobId`

**Available since release:**

This resource is available in API version 47.0 and later.

**Formats:** JSON

**HTTP methods:** GET

**Authentication:** Authorization: Bearer token

**Request parameters:**

| Parameter    | Description              | Required or Optional |
| ------------ | ------------------------ | -------------------- |
| `queryJobId` | The ID of the query job. | Required             |

**Response Body**

```nolang
{
   "id" : "750R0000000zlh9IAA",
   "operation" : "query",
   "object" : "Account",
   "createdById" : "005R0000000GiwjIAC",
   "createdDate" : "2018-12-10T17:50:19.000+0000",
   "systemModstamp" : "2018-12-10T17:51:27.000+0000",
   "state" : "JobComplete",
   "concurrencyMode" : "Parallel",
   "contentType" : "CSV",
   "apiVersion" : 46.0,
   "jobType" : "V2Query",
   "lineEnding" : "LF",
   "columnDelimiter" : "COMMA",
   "numberRecordsProcessed" : 500,
   "retries" : 0,
   "totalProcessingTime" : 334,
   "isPkChunkingSupported": true
}
```

**Response Parameters:**

| Parameter                | Type                | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| ------------------------ | ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `id`                     | string              | The unique ID for this job.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| `operation`              | OperationEnum       | The type of query. Possible values are:<ul><li>`query`—Returns data that hasn’t been deleted or archived. For more information, see [query()](https://developer.salesforce.com/docs/atlas.en-us.api.meta/api/sforce_api_calls_query.htm) in _SOAP API Developer Guide_.</li><li>`queryAll`—Returns records that have been deleted because of a merge or delete, and returns information about archived Task and Event records. For more information, see [queryAll()](https://developer.salesforce.com/docs/atlas.en-us.api.meta/api/sforce_api_calls_queryall.htm) in _SOAP API Developer Guide_.</li></ul> |
| `object`                 | string              | The object type being queried.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| `createdById`            | string              | The ID of the user who created the job.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| `createdDate`            | dateTime            | The UTC date and time when the job was created.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| `systemModstamp`         | dateTime            | The UTC date and time when the API last updated the job information.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |
| `state`                  | JobStateEnum        | The current state of processing for the job. Possible values are: <ul><li>`UploadComplete`—The job is ready to be processed and Salesforce has put the job in the queue.</li><li>`InProgress`—Salesforce is processing the job.</li><li>`Aborted`—The job has been aborted. See [Abort a Query Job](https://developer.salesforce.com/docs/platform/api-asynch/guide/query-abort-job.md).</li><li>`JobComplete`—Salesforce has finished processing the job.</li><li>`Failed`—The job failed.</li></ul>                                                                                                                                                                        |
| `concurrencyMode`        | ConcurrencyModeEnum | Reserved for future use. How the request is processed. Currently only parallel mode is supported. (When other modes are added, the API chooses the mode automatically. The mode isn’t user configurable.)                                                                                                                                                                                                                                                                                                                                                                                                    |
| `contentType`            | ContentType         | The format that is used for the results. Currently the only supported value is `CSV`.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| `apiVersion`             | string              | The API version that the job was created in.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| `jobType`                | JobTypeEnum         | The job’s type. For a query job, the type is always `V2Query`.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| `lineEnding`             | LineEndingEnum      | The line ending used for CSV job data, marking the end of a data row. The default is `LF`. Possible values are:<ul><li>`LF`—linefeed character</li><li>`CRLF`—carriage return character followed by a linefeed character</li></ul>                                                                                                                                                                                                                                                                                                                                                                           |
| `columnDelimiter`        | ColumnDelimiterEnum | The column delimiter used for CSV job data. The default value is `COMMA`. Possible values are:<ul><li>`BACKQUOTE`—back quote character (\`)</li><li>`CARET`—caret character (^)</li><li>`COMMA`—comma character (,)</li><li>`PIPE`—pipe character (\|)</li><li>`SEMICOLON`—semicolon character (;)</li><li>`TAB`—tab character</li></ul>                                                                                                                                                                                                                                                                     |
| `numberRecordsProcessed` | long                | The number of records processed in this job.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| `retries`                | int                 | The number of times that Salesforce attempted to save the results of an operation. Repeated attempts indicate a problem such as a lock contention.                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| `totalProcessingTime`    | long                | The number of milliseconds taken to process the job.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |
| `isPkChunkingSupported`  | boolean             | Whether PK chunking is supported for the queried object (`true`), or isn't supported (`false`).                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |

**Response Body - For an Unsuccessful Request**

If the request fails, the server returns a non-200 status, and the request body shows details of the error. For example, if the [job has been deleted](https://developer.salesforce.com/docs/platform/api-asynch/guide/query-delete-job.md#delete-a-query-job) the status is 404 (Not Found) and the response body is:

```nolang
[{
	"errorCode": "NOT_FOUND",
	"message": "The requested resource does not exist"
}]
```

For details about error codes and messages, see [Errors](https://developer.salesforce.com/docs/platform/api-asynch/reference/bulk-api-2-0-errors.md).

## Example

This example gets information about the job with ID `750R0000000zxikIAA`:

```nolang
curl --include --request GET \
--header "Authorization: Bearer token" \
"https://instance.salesforce.com/services/data/vXX.X/jobs/query/750R0000000zxikIAA
```

The response is:

```nolang
{
   "id" : "750R0000000zxikIAA",
   "operation" : "query",
   "object" : "Account",
   "createdById" : "005R0000000GiwjIAC",
   "createdDate" : "2018-12-18T22:51:36.000+0000",
   "systemModstamp" : "2018-12-18T22:51:58.000+0000",
   "state" : "JobComplete",
   "concurrencyMode" : "Parallel",
   "contentType" : "CSV",
   "apiVersion" : 46.0,
   "jobType" : "V2Query",
   "lineEnding" : "LF",
   "columnDelimiter" : "COMMA",
   "numberRecordsProcessed" : 740003,
   "retries" : 0,
   "totalProcessingTime" : 21046,
   "isPkChunkingSupported": true
}
```
