Note
- For OceanBase Database V4.3.x, this variable was introduced in OceanBase Database V4.3.3.
- For OceanBase Database V4.2.x, this variable was introduced in OceanBase Database V4.2.4.
Purpose
The oceanbase.DBA_SCHEDULER_JOB_RUN_DETAILS view displays all scheduler jobs in the current tenant.
Columns
| Column | Type | Nullable? | Description |
|---|---|---|---|
| LOG_ID | decimal(10,0) | NO | The log ID of the log record. At present, this column is not supported and its value is NULL by default. |
| LOG_DATE | datetime | NO | The log record. |
| OWNER | varchar(128) | NO | The owner of the job. |
| JOB_NAME | varchar(128) | NO | The name of the job. |
| JOB_SUBNAME | varchar(128) | NO | The subname of the job. At present, this column is not supported and its value is NULL by default. |
| STATUS | varchar(128) | NO | The status of the job. |
| CODE | bigint(20) | YES | The error code of the job running error. |
| REQ_START_DATE | datetime | NO | The expected start time of the job. |
| ACTUAL_START_DATE | datetime | NO | The actual start time of the job. |
| RUN_DURATION | decimal(10,0) | NO | The duration of the job. At present, this column is not supported and its value is NULL by default. |
| INSTANCE_ID | varchar(128) | NO | At present, this column is not supported and its value is NULL by default. |
| SESSION_ID | decimal(10,0) | NO | At present, this column is not supported and its value is NULL by default. |
| SLAVE_PID | varchar(128) | NO | The PID of the subprogress called by the job. At present, this column is not supported and its value is NULL by default. |
| CPU_USED | decimal(10,0) | NO | The CPU utilization of the job. At present, this column is not supported and its value is NULL by default. |
| CREDENTIAL_OWNER | varchar(128) | NO | At present, this column is not supported and its value is NULL by default. |
| CREDENTIAL_NAME | varchar(128) | NO | At present, this column is not supported and its value is NULL by default. |
| DESTINATION_OWNER | varchar(128) | NO | At present, cross-database jobs are not supported, and the value of this column is NULL by default. |
| DESTINATION | varchar(128) | NO | At present, cross-database jobs are not supported, and the value of this column is NULL by default. |
| MESSAGE | varchar(4000) | NO | The error message of the job running error. |
| JOB | bigint(20) | NO | The name of the scheduler job. |
| TIME | timestamp(6) | NO | The time when the job running log was recorded. The value is a timestamp in seconds. |
| JOB_CLASS | varchar(30) | YES | The class of the scheduler job. |
| GMT_CREATE | timestamp(6) | YES | The time when the scheduler job was created. The value is a timestamp in seconds. |
| GMT_MODIFIED | timestamp(6) | YES | The time when the scheduler job was modified. The value is a timestamp in seconds. |
Sample query
obclient [oceanbase]> SELECT * FROM oceanbase.DBA_SCHEDULER_JOB_RUN_DETAILS limit 1\G
The query result is as follows:
*************************** 1. row ***************************
LOG_ID: 0
LOG_DATE: NULL
OWNER: NULL
JOB_NAME: ASYNC_GATHER_STATS_JOB_PROC
JOB_SUBNAME: NULL
STATUS: NULL
CODE: 0
REQ_START_DATE: NULL
ACTUAL_START_DATE: NULL
RUN_DURATION: NULL
INSTANCE_ID: NULL
SESSION_ID: NULL
SLAVE_PID: NULL
CPU_USED: NULL
CREDENTIAL_OWNER: NULL
CREDENTIAL_NAME: NULL
DESTINATION_OWNER: NULL
DESTINATION: NULL
MESSAGE: SUCCESS
JOB: 9
TIME: 2024-06-05 15:18:03.867194
JOB_CLASS: DEFAULT_JOB_CLASS
GMT_CREATE: 2024-06-05 15:18:03.867194
GMT_MODIFIED: 2024-06-05 15:18:03.867194
1 row in set (0.008 sec)