(mysql.info) begin-end
Info Catalog
(mysql.info) call
(mysql.info) stored-procedure-syntax
(mysql.info) declare
17.2.5 `BEGIN ... END' Compound Statement Syntax
------------------------------------------------
[BEGIN_LABEL:] BEGIN
[STATEMENT_LIST]
END [END_LABEL]
`BEGIN ... END' syntax is used for writing compound statements, which
can appear within stored routines and triggers. A compound statement
can contain multiple statements, enclosed by the `BEGIN' and `END'
keywords. STATEMENT_LIST represents a list of one or more statements.
Each statement within STATEMENT_LIST must be terminated by a semicolon
(`;') statement delimiter. Note that STATEMENT_LIST is optional, which
means that the empty compound statement (`BEGIN END') is legal.
Use of multiple statements requires that a client is able to send
statement strings containing the `;' statement delimiter. This is
handled in the `mysql' command-line client with the `delimiter'
command. Changing the `;' end-of-statement delimiter (for example, to
`//') allows `;' to be used in a routine body. For an example, see
create-procedure.
A compound statement can be labeled. END_LABEL cannot be given unless
BEGIN_LABEL also is present. If both are present, they must be the same.
The optional `[NOT] ATOMIC' clause is not yet supported. This means
that no transactional savepoint is set at the start of the instruction
block and the `BEGIN' clause used in this context has no effect on the
current transaction.
Info Catalog
(mysql.info) call
(mysql.info) stored-procedure-syntax
(mysql.info) declare
automatically generated byinfo2html