CALL

Stai visualizzando una vecchia versione di questo article. Visualizza la versione più recente.

Sintassi

CALL nome_sp([parametro[, ...]])
CALL nome_sp[()]

Spiegazione

L'istruzione CALL invoca una Stored Procedure che è stata definita precedentemente con CREATE PROCEDURE.

A partire da MySQL 5.1.13, le Stored Procedure che non richiedono argomenti possono essere chiamate senza parentesi. Questo significa che CALL p() e CALL p sono equivalenti.

CALL can pass back values to its caller using parameters that are declared as OUT or INOUT parameters. When the procedure returns, a client program can also obtain the number of rows affected for the final statement executed within the routine: At the SQL level, call the ROW_COUNT() function; from the C API, call the mysql_affected_rows() function.

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.