Difference between REF Cursor & Normal Cursor in oracle

What is the difference between REF Cursor & Normal Cursor in oracle?

REF cursor is typically used to return record set or a cursor from stored procedure. REF Cursor is basically a data type. It is normally declared as type r_cursor is REF CURSOR; REF cursor supports dynamic change of query.

Normal cursor is a static cursor in which the query is assigned at design time and cant be changed at run time.

What is the difference between REF Cursor & Normal Cursor in oracle?

Normal cursors fall under the category of static cursors while REF cursors are dynamic. This means that normal cursors can only be used again not defined. Ref cursors on the other hand can be changed. A Ref cursor can be passed from one procedure to another. A normal cursor cannot.
What is Global temporary table in oracle? and what are the benefits of it?
GLOBAL TEMPORARY TABLE is used to store temporary data in scenarios where complex calculation is involved....
What is Pragma Init Exception in oracle?
Pragma init exception is used to associate a user defined exception with an error number and a custom message....
Disadvantages of trigger in oracle.
Triggers can execute every time some field in database is updated. If a field is likely to be updated often, it is a system overhead.......
Post your comment

You may like