<= MariaDB 10.2
OPEN cursor_name
From MariaDB 10.3
OPEN cursor_name [expression[,...]];
This statement opens a cursor which was previously declared with DECLARE CURSOR.
The query associated to the DECLARE CURSOR is executed when OPEN is executed. It is important to remember this if the query produces an error, or calls functions which have side effects.
This is necessary in order to FETCH rows from a cursor.
See Cursor Overview for an example.
© 2019 MariaDB
Licensed under the Creative Commons Attribution 3.0 Unported License and the GNU Free Documentation License.
https://mariadb.com/kb/en/open/