现在的位置: 首页 > 综合 > 正文

pl/sql 记录表–对象数组

2013年10月18日 ⁄ 综合 ⁄ 共 790字 ⁄ 字号 评论关闭

-- Created on 2011-7-20 by ZXX

declare -- Local variables here

i integer;

type flag_type is TABLE OF int INDEX BY BINARY_INTEGER;

type list_type is table of t_heart_progress%ROWTYPE index by binary_integer;

list list_type;

list_flag flag_type;

v_area varchar2(10);

SQL_IN varchar2(5000);

Nv_counts number;

Nv_max number;

Nv_min number;

begin -- Test statements here

list(570).areacode :='570';

list(570).allcounts :=100;

list(570).allcounts :=100;

list(570).sendcounts :=100;

list(570).allchunnel :=100;

list(570).usedchunnel :=100;

list(570).speed :=100;

list(570).progressrate :=100;

list(570).stime :=sysdate;

list(570).etime :=sysdate;

list(570).usedtime :=100;

list(570).counter :=100;

list_flag(570) :=1;

 v_area :=list(570).areacode;

SQL_IN := 'select count(*),max(lsspeed), min(chnspeed) from t_area_alloc';

execute immediate SQL_IN into Nv_counts,nv_max,nv_min; --记录数

end;

抱歉!评论已关闭.