qua_help_jobs#

Fetches a data set with details of all jobs that a scheduler is aware of. This procedure helps with the current state of the Querona internal job scheduler. The result set contains all the jobs registered, regardless they are scheduled or not. When there are multiple triggers on a job a result row represents details at a trigger level.

Syntax#

qua_help_jobs

Result Sets#

Column name

Data type

Description

JobKey

varchar(200)

An internal key of the job.

JobName

nvarchar(512)

Name of the job.

JobId

uniqueidentifier

ID of the job.

TriggerKey

varchar(526)

An internal key of the job’s trigger.

ScheduleId

int

A schedule ID which the trigger is assigned to.

TriggerStartDate

datetime2

The time at which the trigger’s scheduling should start.

TriggerEndDate

datetime2

The date when the trigger must stop firing.

TriggerNextFireTime

datetime2

The next time at which the trigger is scheduled to fire.

LastJobExecutionStartDate

datetime2

Most recently finished job execution start date with time.

LastJobExecutionFinishDate

datetime2

Most recently finished job execution end date with time.

LastJobExecutionNextFireTime

datetime2

Most recently finished job execution’s parent job could be planned to fire up again. The value represents the contemporary planned fire time.

LastJobExecutionErrorMessage

nvarchar(max)

Most recently finished job execution error message if any.

TriggerState

nvarchar(128)

An internal trigger state. The following states are supported:

  • Normal - indicates that the trigger is in the “normal” state.

  • Paused - indicates that the trigger is in the “paused” state.

  • Complete - indicates that the trigger has no remaining fire-times in its schedule.

  • Error - a trigger arrives at the error state when the scheduler attempts to fire it, but cannot due to an error creating and executing its related job. When the trigger is in the error state, the scheduler will make no attempts to fire it.

  • Blocked - a trigger arrives at the blocked state when the job that it is associated with disallows concurrent execution and it is currently executing.

  • None - indicates that the trigger does not exist.

Example#

EXEC qua_help_jobs;