ALTER EVENT
Stai visualizzando una vecchia versione di questo article. Visualizza
la versione più recente.
Sintassi
ALTER [DEFINER = { utente | CURRENT_USER }] EVENT nome_evento [ON SCHEDULE schedule] [ON COMPLETION [NOT] PRESERVE] [RENAME TO nuovo_nome] [ENABLE | DISABLE | DISABLE ON SLAVE] [COMMENT 'commento'] [DO istruzione_sql]
Spiegazione
L'istruzione ALTER EVENT
serve a modificare una o più fra le caratteristiche di un evento esistente senza rimuoverlo e ricrearlo. La sintassi delle clausole DEFINER
, ON SCHEDULE
, ON COMPLETION
, COMMENT
, ENABLE
/
DISABLE
e DO
è esattamente la stessa che si usa in CREATE EVENT
.
Il supporto alla clausola DEFINER
è stato aggiunto in MySQL 5.1.17.
Beginning with MySQL 5.1.12, this statement requires the EVENT
privilege.
When a user executes a successful ALTER EVENT
statement, that user becomes
the definer for the affected event.
(In MySQL 5.1.11 and earlier, an event could be altered only by its definer, or
by a user having the SUPER
privilege.)
ALTER EVENT
works only with an existing event:
MariaDB [test]> ALTER EVENT no_such_event ON SCHEDULE EVERY '2:3' DAY_HOUR; ERROR 1539 (HY000): Unknown event 'no_such_event' MariaDB [test]>
Commenti
Sto caricando i commenti......
Content reproduced on this site is the property of its respective owners,
and this content is not reviewed in advance by MariaDB. The views, information and opinions
expressed by this content do not necessarily represent those of MariaDB or any other party.