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 Use "FOR" Statements
How To Use "FOR" Statements? - Oracle DBA FAQ - Understanding PL/SQL Language Basics
✍: FYIcenter.com
If you have a block of codes to be executed repeatedly over a range of values, you can use the "FOR ... LOOP" statement. Here is a sample script on FOR statements:
DECLARE
total NUMBER := 0;
BEGIN
FOR i IN 1..10 LOOP
total := total + i;
END LOOP;
DBMS_OUTPUT.PUT_LINE('Total: ' || TO_CHAR(total));
END;
Note that temporary variable "i" used in the FOR loop needs no declaration. This script should print this:
Total: 55
2007-04-29, 5718👍, 0💬
Popular Posts:
What is Concern in AOP? gA concern is a particular goal, concept, or area of interesth There are m...
What is the difference between const char* p and char const* p? In const char* p, the character poin...
What is CodeDom? “CodeDom” is an object model which represents actually a source code. It is designe...
What is cross page posting? By default, button controls in ASP.NET pages post back to the same page ...
How To Write a Minimum Atom 1.0 Feed File? - RSS FAQs - Atom Feed Introduction and File Generation I...