Categories:
.NET (357)
C (330)
C++ (183)
CSS (84)
DBA (2)
General (7)
HTML (4)
Java (574)
JavaScript (106)
JSP (66)
Oracle (114)
Perl (46)
Perl (1)
PHP (1)
PL/SQL (1)
RSS (51)
Software QA (13)
SQL Server (1)
Windows (1)
XHTML (173)
Other Resources:
How To Loop through Data Rows in the Implicit Curosr
How To Loop through Data Rows in the Implicit Curosr? - Oracle DBA FAQ - Working with Cursors in PL/SQL
✍: FYIcenter.com
You use the FOR ... IN ... LOOP statement to loop through data rows in the implicit cursor as the following syntax:
FOR row IN dml_statement LOOP
(statement block with row.field)
END LOOP;
Here "row" is a local RECORD type variable with fields automatically defined to match the fields in the data rows resulted from the DML statement. Here is a good tutorial exercise on loop through data rows with the implicit cursor:
BEGIN
FOR row IN (SELECT * FROM employees
WHERE manager_id = 101) LOOP
DBMS_OUTPUT.PUT_LINE('Name = ' || row.last_name);
END LOOP;
END;
/
Name = Greenberg
Name = Whalen
Name = Mavris
Name = Baer
Name = Higgins
2007-04-29, 5290👍, 0💬
Popular Posts:
How To Merge Cells in a Row? - XHTML 1.0 Tutorials - Understanding Tables and Table Cells If you wan...
How To Control Vertical Alignment? - XHTML 1.0 Tutorials - Understanding Tables and Table Cells By d...
How To Write a Minimum Atom 1.0 Feed File? - RSS FAQs - Atom Feed Introduction and File Generation I...
How To Merge Cells in a Column? - XHTML 1.0 Tutorials - Understanding Tables and Table Cells If you ...
How can you determine the size of an allocated portion of memory? You can't, really. free() can , bu...