Oracle implicit cursor is a typical type of cursor. The following describes the usage of Oracle implicit cursor for your reference. It is helpful for you to learn about Oracle database.
Oracle implicit cursor:
You do not need to explicitly create a cursor variable. Oracle implicit cursors can be divided into two types:
1. Use the DML language in PL/SQL and use the implicit cursor "SQL" provided by ORACLE.
Example:
- declare
-
- begin
-
- update departments set department_namedepartment_name=department_name;
-
- --where 1=2;
-
- dbms_output.put_line('update '|| sql%rowcount ||' records');
-
- end;
-
- /
2. cursor for loop, used for the FOR loop statement
Example:
- declare
-
- begin
-
- for my_dept_rec in ( select department_name, department_id from departments)
-
- loop
-
- dbms_output.put_line(my_dept_rec.department_id || ' : ' || my_dept_rec.department_name);
-
- end loop;
-
- end;
-
- /
Use instances of Oracle stored procedures
Oracle command line custom editor vi
Implementation of oracle command line Logon
Oracle queries table space usage
Syntax for creating views in Oracle