Collections:
Define a Cursor Variable in Oracle
How To Define a Cursor Variable in Oracle?
✍: FYIcenter.com
To define cursor variable, you must decide which REF CURSOR data type to use. There are 3 ways to select a REF CURSOR data type:
The follwoing tutorial exercise defines 3 cursor variables in 3 different ways:
CREATE OR REPLACE PROCEDURE FYI_CENTER AS TYPE emp_ref IS REF CURSOR RETURN employees%ROWTYPE; TYPE any_ref IS REF CURSOR; emp_cur emp_ref; any_cur any_ref; sys_cur SYS_REFCURSOR; BEGIN NULL; END; /
2018-07-18, 835👍, 0💬
Popular Posts:
Where to find MySQL database server tutorials? Here is a collection of tutorials, tips and FAQs for ...
How to set database to be READ_ONLY in SQL Server? Databases in SQL Server have two update options: ...
How To Create a Table in a Specific Tablespace in Oracle? After you have created a new tablespace, y...
How To Count Rows with the COUNT(*) Function in SQL Server? If you want to count the number of rows,...
How To Define Output Parameters in Stored Procedures in SQL Server Transact-SQL? Sometime a stored p...