- 爱易网页
 
                        - 
                            数据库教程
 
                        - 遍历联系关系数组  index by varchar2 
 
                         
                    
                    
                    日期:2014-05-16  浏览次数:20471 次 
                    
                        
                         遍历关联数组  index by varchar2
--字符串序列要这样
declare
    type t   is table of number(3) index by varchar2(3);
   hash_t t;  
   l_row varchar2(3);
  begin
  hash_t('a') := 10;
  hash_t('b') := 20;  
  l_row :=hash_t.first;
  while(l_row is not null) loop
  dbms_output.put_line(hash_t(l_row));
  l_row:=hash_t.next(l_row);
  end loop;
  end;
--数字序列可以这样