Documentation Home
MySQL 8.0 Reference Manual
Related Documentation Download this Manual
PDF (US Ltr) - 43.3Mb
PDF (A4) - 43.4Mb
Man Pages (TGZ) - 297.3Kb
Man Pages (Zip) - 402.5Kb
Info (Gzip) - 4.3Mb
Info (Zip) - 4.3Mb
Excerpts from this Manual

MySQL 8.0 Reference Manual  / ...  / SQL Statements  / Prepared Statements  /  DEALLOCATE PREPARE Statement

15.5.3 DEALLOCATE PREPARE Statement

{DEALLOCATE | DROP} PREPAREstmt_name

To deallocate a prepared statement produced withPREPARE, use aDEALLOCATE PREPARE statement that refers to the prepared statement name. Attempting to execute a prepared statement after deallocating it results in an error. If too many prepared statements are created and not deallocated by either theDEALLOCATE PREPARE statement or the end of the session, you might encounter the upper limit enforced by themax_prepared_stmt_count system variable.

For examples, seeSection 15.5, “Prepared Statements”.