ADMIN RESUME DDL allows you to resume a paused DDL job. You can find the
job_id by running
ADMIN SHOW DDL JOBS.
You can use this statement to resume a paused DDL job. After the resume is completed, the SQL statement that executes the DDL job continues to show as being executed. If you try to resume a DDL job that has already been completed, you will see the
DDL Job:90 not found error in the
RESULT column, which indicates that the job has been removed from the DDL waiting queue.
AdminStmt ::= 'ADMIN' ( 'SHOW' ( 'DDL' ( 'JOBS' Int64Num ) | 'RECOVER' 'INDEX' TableName Identifier | 'CLEANUP' ( 'INDEX' TableName Identifier | 'TABLE' 'LOCK' TableNameList ) | 'CHECKSUM' 'TABLE' TableNameList | 'CANCEL' 'DDL' 'JOBS' NumList | 'PAUSE' 'DDL' 'JOBS' NumList | 'RESUME' 'DDL' 'JOBS' NumList | 'RELOAD' ( 'EXPR_PUSHDOWN_BLACKLIST' | 'OPT_RULE_BLACKLIST' | 'BINDINGS' ) | 'PLUGINS' ( 'ENABLE' | 'DISABLE' ) PluginNameList | 'REPAIR' 'TABLE' TableName CreateTableStmt | ( 'FLUSH' | 'CAPTURE' | 'EVOLVE' ) 'BINDINGS' ) NumList ::= Int64Num ( ',' Int64Num )*
ADMIN RESUME DDL JOBS resumes the currently paused DDL job and returns whether the job is resumed successfully.
ADMIN RESUME DDL JOBS job_id [, job_id] ...;
If the resume fails, the specific reason for the failure is displayed.
This statement is a TiDB extension to MySQL syntax.