How To Define an Explicit Cursor

Q

How To Define an Explicit Cursor? - Oracle DBA FAQ - Working with Cursors in PL/SQL

✍: FYIcenter.com

A

An explicit cursor must be defined in the declaration part of a procedure or function with the CURSOR ... IS statement as shown in the following sample script:

DECLARE
  CURSOR c_list IS SELECT * FROM countries;
  CURSOR t_list IS SELECT * FROM employees
    WHERE employee_id = 100;
BEGIN
  NULL;
END;
/

2007-04-29, 4865👍, 0💬