advanced code snippet search
geekzspot on 02/20/13
02/20/13 11:03am02/20/13 10:50am
Loop through a fixed list of values or strings
DECLARE TYPE string_array IS TABLE OF VARCHAR(1); rainbow_colors string_array := string_array('Red', 'Orange', 'Yellow', 'Green', 'Blue', 'Indigo', 'Violet');BEGIN FOR i IN 1..rainbow_colors .COUNT LOOP DBMS_OUTPUT.PUT_LINE(rainbow_colors (i)); END LOOP;END;
Report this snippet Tweet
Comment:
You need to login to post a comment.