Cursor:
Cursor is a memory variable, it take space with in row and column.it also can take matrix data.
Also ,A cursor is a pointer that points to a result of a query.
PL/SQL has two types of cursors:
•Implicit cursors
•Explicit cursors
Implicit Cursors
Whenever Oracle executes an SQL statement such as Select Into , Insert , Update and Delete it automatically creates an implicit cursor.
Implicit Cursors Example:
Explicit cursors
An explicit cursor is an Select statement declared explicitly in the declaration section of the current block or a package specification.
Explicit cursors Example:
Cursor with parameters:
Example:
PLSQL Records and Cursor:
Difference between records and cursor is : Cursor take data from direct table where records take data from cursor.
Cursor FOR Loops:
Example: