Skip to main content
The RESUME JOB lets you resume the following types of jobs:
  • jobs
  • and jobs
  • jobs
  • jobs
  • jobs
  • jobs

Required privileges

To resume a job, the user must be a member of the admin role or must have the set. Non-admin users cannot resume admin users’ jobs. For changefeeds, users with the privilege on a set of tables can resume changefeed jobs running on those tables.

Synopsis

resume_job syntax diagram

Resume all jobs by type

resume_all_jobs syntax diagram

Parameters

ParameterDescription
job_idThe ID of the job you want to resume, which can be found with .
select_stmtA that returns job_id(s) to resume.
for_schedules_clauseThe schedule you want to resume jobs for. You can resume jobs for a specific schedule (FOR SCHEDULE id) or resume jobs for multiple schedules by nesting a in the statement (FOR SCHEDULES <select_clause>). See the examples below.
BACKUP, CHANGEFEED, RESTORE, IMPORTThe job type to resume.

Examples

Pause a job

> SHOW JOBS;
      job_id     |  job_type |               description                      |...
-----------------+-----------+------------------------------------------------+...
  27536791415282 |  RESTORE  | RESTORE db.* FROM 'azure-blob://backup/db/tbl' |...
> PAUSE JOB 27536791415282;

Resume a single job

> RESUME JOB 27536791415282;

Resume multiple jobs

To resume multiple jobs, nest a that retrieves job_id(s) inside the RESUME JOBS statement:
> RESUME JOBS (WITH x AS (SHOW JOBS) SELECT job_id FROM x
      WHERE user_name = 'maxroach');
All jobs created by maxroach will be resumed.

Resume by job type

To resume all jobs by the type of job, use the RESUME ALL {job} JOBS statement. You can resume all BACKUP, RESTORE, CHANGEFEED, IMPORT jobs using this statement, for example:
RESUME ALL BACKUP JOBS;

Resume jobs for a schedule

To resume jobs for a specific , use the schedule’s id:
> RESUME JOBS FOR SCHEDULE 590204387299262465;
RESUME JOBS FOR SCHEDULES 1
You can also resume multiple schedules by nesting a that retrieves id(s) inside the PAUSE JOBS statement:
> RESUME JOBS FOR SCHEDULES WITH x AS (SHOW SCHEDULES) SELECT id FROM x WHERE label = 'test_schedule';
RESUME JOBS FOR SCHEDULES 2

See also