OPEN_CURSOR v11

The OPEN_CURSOR function creates a new cursor. A cursor must be used to parse and execute any dynamic SQL statement. Once a cursor has been opened, it can be re-used with the same or different SQL statements. The cursor does not have to be closed and re-opened in order to be re-used.

<c> INTEGER OPEN_CURSOR

Parameters

c

Cursor ID number associated with the newly created cursor.

Examples

The following example creates a new cursor:

DECLARE
    curid           INTEGER;
BEGIN
    curid := DBMS_SQL.OPEN_CURSOR;
            .
            .
            .
END;