QUERY WATCH
The QUERY WATCH
statement is used to manually manage the watch list of runaway queries in a resource group.
Synopsis
- AddQueryWatchStmt
- QueryWatchOptionList
- QueryWatchOption
- ResourceGroupName
- ResourceGroupRunawayActionOption
- QueryWatchTextOption
- ResourceGroupRunawayWatchOption
- DropQueryWatchStmt
AddQueryWatchStmt ::=
"QUERY" "WATCH" "ADD" QueryWatchOptionList
QueryWatchOptionList ::=
QueryWatchOption
| QueryWatchOptionList QueryWatchOption
| QueryWatchOptionList ',' QueryWatchOption
QueryWatchOption ::=
"RESOURCE" "GROUP" ResourceGroupName
| "RESOURCE" "GROUP" UserVariable
| "ACTION" EqOpt ResourceGroupRunawayActionOption
| QueryWatchTextOption
ResourceGroupName ::=
Identifier
| "DEFAULT"
ResourceGroupRunawayActionOption ::=
DRYRUN
| COOLDOWN
| KILL
| "SWITCH_GROUP" '(' ResourceGroupName ')'
QueryWatchTextOption ::=
"SQL" "DIGEST" SimpleExpr
| "PLAN" "DIGEST" SimpleExpr
| "SQL" "TEXT" ResourceGroupRunawayWatchOption "TO" SimpleExpr
ResourceGroupRunawayWatchOption ::=
"EXACT"
| "SIMILAR"
| "PLAN"
DropQueryWatchStmt ::=
"QUERY" "WATCH" "REMOVE" NUM
Parameters
MySQL compatibility
This statement is a TiDB extension to MySQL syntax.