SQL> declare
2 type varchar_array is table of varchar2(100) index by binary_integer;
3 array1 varchar_array;
4 v_index number;
5 begin
6 array1(1) := 'T';
7 array1(2) := 'R';
8 array1(5) := 'B';
9
10 v_index := array1.first;
11
12 for x in 1..array1.count loop
13 dbms_output.put_line(array1(v_index) );
14 v_index := array1.next(v_index);
15 end loop;
16 end;
17 /
PL/SQL procedure successfully completed.
SQL>
SQL>
|