Querying the Job Execution Result-Method 2 (Discarded)
Function
This API is used to view the job execution result after a job is executed using SQL query statements. Currently, you can only query execution results of jobs of the QUERY type.
You can view the first 1000 result records only. To view all result records, export them first. For details, see Exporting Query Results.
URI
- URI format
GET/v1.0/{project_id}/jobs/{job_id}?page-size={size}¤t-page={page_number}&queue-name={queue_name}
- Parameter description
Table 1 URI parameters Parameter
Mandatory
Description
project_id
Yes
Project ID, which is used for resource isolation. For details about how to obtain its value, see Obtaining a Project ID.
job_id
Yes
Job ID.
page-size
No
Maximum number of lines displayed on each page. The value range is as follows: [1, 100]. The default value is 50.
current-page
No
Current page number. The default value is 1.
queue-name
No
Name of the execution queue for obtaining job results. If this parameter is not specified, the default system queue is used.
Request
None
Response
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| is_success | No | Boolean | Indicates whether the request is successfully executed. Value true indicates that the request is successfully executed. |
| message | No | String | System prompt. If execution succeeds, the parameter setting may be left blank. |
| job_id | No | String | Job ID. |
| job_type | No | String | Job type, including DDL, DCL, IMPORT, EXPORT, QUERY, INSERT, DATA_MIGRATION, UPDATE, DELETE, RESTART_QUEUE and SCALE_QUEUE. Currently, you can only query execution results of jobs of the QUERY type. |
| row_count | No | Integer | Total number of job results. |
| input_size | No | long | Amount of data scanned during job execution. |
| schema | No | Array of objects | Name and type of the job result column. |
| rows | No | Array of objects | Job results set. |
Example
- Example request
None
- Example response (successful request)
{ "is_success": true, "message": "", "job_id": "ead0b276-8ed4-4eb5-b520-58f1511e7033", "job_type": "QUERY", "row_count": 1, "input_size": 74, "schema": [ { "c1": "int" }, { "c2": "string" } ], "rows": [ [ 23, "sda" ] ] }
If an error occurs when this API is invoked, the system does not return the result similar to the preceding example, but returns the error code and error information. For details, see Error Code.
Last Article: Querying the Job Execution Result-Method 1 (Discarded)
Next Article: APIs Related to Data Upload (Discarded)
Did this article solve your problem?
Thank you for your score!Your feedback would help us improve the website.