%found - explicit cursor attributes, PL-SQL Programming


Subsequent to a cursor or cursor variable is opened but before the first fetch, the %FOUND yields NULL. Afterward, it yields TRUE when the last fetch returned a row, or FALSE when the final fetch failed to return a row. In the illustration below, you use %FOUND to select an action:


FETCH c1 INTO my_ename, my_sal, my_hiredate;

IF c1%FOUND THEN -- fetch succeeded


ELSE -- fetch failed, so exit loop




When the cursor or cursor variable is not open, referencing it with the %FOUND raises the predefined exception INVALID_CURSOR.

Posted Date: 10/4/2012 4:09:48 AM | Location : United States

Related Discussions:- %found - explicit cursor attributes, Assignment Help, Ask Question on %found - explicit cursor attributes, Get Answer, Expert's Help, %found - explicit cursor attributes Discussions

Write discussion on %found - explicit cursor attributes
Your posts are moderated
Related Questions
Initializing Records The illustration below shows that you can initialize a record in its type definition. Whenever you declare a record of the type TimeRec, its 3 fields supp

Datatypes Every constant and variable has a datatype that specifies the storage format, constraints, and the valid range of values. The PL/SQL gives a variety of predefined dat

EXIT-WHEN The EXIT-WHEN statement permits a loop to complete conditionally. Whenever the EXIT statement is encountered, the condition in the WHEN clause is computed. When the co

Write a program to implement the inverted file shown in the slides (Simple Index file, LabelID file and Data file).  Use the Avail_List to point at the deleted Label IDs so that th

Perform the following queries on the Hospital1.DB using SQL Anywhere (START EARLY!). a. Which patients have purchased the drug "Tylenol"? List the names and addresses. Arrange the

Parameter & Keyword Description: function_name: The user-defined function is identifying by that keyword. parameter_name: This identifies the formal parameter that

Advantages of Invoker Rights The Invoker-rights routines centralize the data retrieval. They are particularly helpful in applications which store data in various schemas. In su

Data Types in SQL SQL's concept does not differ significantly from that defined in the theory book, apart from that business concerning NULL. However, the theory book equates

Semidifference via NOT IN and a subquery SELECT StudentId FROM IS_CALLED WHERE Name = 'Devinder' AND StudentId NOT IN (SELECT StudentId FROM IS_ENROLLED_ON WHER

%TYPE: This attribute gives the datatype of a formerly declared collection, cursor variable, object, field, record, database column, or variable. Datatype: This is simply