Opening a cursor, PL-SQL Programming

Opening a Cursor

Opening the cursor executes the query & identifies the result set that consists of all rows that meet the query search criteria. For the cursors declared using the FOR UPDATE clause, the OPEN statement also locks these rows. An illustration of the OPEN statement is as shown:


CURSOR c1 IS SELECT ename, job FROM emp WHERE sal < 3000;



OPEN c1;



The Rows in the result set are not retrieved when the OPEN statement is executed. Instead, the FETCH statement retrieves the rows.

Posted Date: 10/4/2012 3:52:25 AM | Location : United States

Related Discussions:- Opening a cursor, Assignment Help, Ask Question on Opening a cursor, Get Answer, Expert's Help, Opening a cursor Discussions

Write discussion on Opening a cursor
Your posts are moderated
Related Questions
Challenge 1 You are required to do the project and write a test plan for it. Demo 4 is a check writer program for employees. In it, the user enters all information about the

Using the student and faculty tables create a select query that outputs all students for a specific advisor. Generate the execution plan, select out the explain plan . Create an

Naming Conventions The similar naming conventions apply to all PL/SQL program items and units including the variables, cursors, constants, cursor variables, procedures, exception

Parameter and Keyword Description: EXIT: An unconditional EXIT statement (i.e., one without a WHEN clause) exits the present loop instantly. The Execution resumes with th

Using Pragma RESTRICT_REFERENCES: The function called from the SQL statements should obey certain rules meant to control the side effects. To check for violation of the rules,

Using COMMIT The COMMIT statements end the present transaction and make permanent any changes made during that transaction. Till you commit the changes, other users cannot acc

Synonyms You can create the synonyms to provide location transparency for the remote schema objects like tables, views, sequences, stand-alone subprograms, and packages. Though,

#quesWrite a cursor to open an employee database and fetch the employee record whose age is greater than 45.tion..


Using Operator VALUE: As you may expect, the operator VALUE returns the value of an object. The VALUE takes its argument a correlation variable.  For illustration, to return a