UPDATE WHERE CURRENT OF  and DELETE WHERE CURRENT OF  are not implemented, because updatable cursors are not supported. 

Cursors are nonholdable (not held open after a commit). 

Cursors are asensitive. 

Cursors are nonscrollable. 

Cursors are not named. The statement handler acts as the cursor ID. 

You can have open only a single cursor per prepared statement. If you need several cursors, you must prepare several statements. 

You cannot use a cursor for a statement that generates a result set if the statement is not supported in prepared mode. This includes statements such as CHECK TABLE , HANDLER READ , and SHOW BINLOG EVENTS . 

## 13.6.7 Condition Handling 

Conditions may arise during stored program execution that require special handling, such as exiting the current program block or continuing execution. Handlers can be defined for general conditions such as warnings or exceptions, or for specific conditions such as a particular error code. Specific conditions can be assigned names and referred to that way in handlers. 

To name a condition, use the DECLARE ... CONDITION  statement. To declare a handler, use the DECLARE ... HANDLER  statement. See Section 13.6.7.1, “DECLARE ... CONDITION Statement” , and Section 13.6.7.2, “DECLARE ... HANDLER Statement” . For information about how the server chooses handlers when a condition occurs, see Section 13.6.7.6, “Scope Rules for Handlers” . 

To raise a condition, use the SIGNAL  statement. To modify condition information within a condition handler, use RESIGNAL . See Section 13.6.7.1, “DECLARE ... CONDITION Statement” , and Section 13.6.7.2, “DECLARE ... HANDLER Statement” . 

To retrieve information from the diagnostics area, use the GET DIAGNOSTICS  statement (see Section 13.6.7.3, “GET DIAGNOSTICS Statement” ). For information about the diagnostics area, see Section 13.6.7.7, “The MySQL Diagnostics Area” . 

## 13.6.7.1 DECLARE ... CONDITION Statement 

DECLARE condition_name  CONDITION FOR condition_value condition_value : { mysql_error_code | SQLSTATE [VALUE] sqlstate_value } 

The DECLARE ... CONDITION  statement declares a named error condition, associating a name with a condition that needs specific handling. The name can be referred to in a subsequent DECLARE ... HANDLER  statement (see Section 13.6.7.2, “DECLARE ... HANDLER Statement” ). 

Condition declarations must appear before cursor or handler declarations. 

The condition_value  for DECLARE ... CONDITION  indicates the specific condition or class of conditions to associate with the condition name. It can take the following forms: 

• mysql_error_code : An integer literal indicating a MySQL error code. 

