13.5.3 DEALLOCATE PREPARE Statement语句

{DEALLOCATE | DROP} PREPARE stmt_name

To deallocate a prepared statement produced with PREPARE, use a DEALLOCATE PREPARE statement that refers to the prepared statement name. 若要取消分配使用PREPARE生成的已准备语句,请使用引用已准备语句名称的DEALLOCATE PREPARE语句。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 the DEALLOCATE PREPARE statement or the end of the session, you might encounter the upper limit enforced by the max_prepared_stmt_count system variable.如果创建了太多的准备语句,并且没有通过DEALLOCATE PREPARE语句或会话结束释放,则可能会遇到max_prepared_stmt_count系统变量强制执行的上限。

For examples, see Section 13.5, “Prepared Statements”.例如,请参阅第13.5节,“准备好的语句”