oracle的存储过程中不能直接select,必须要将结果放到变量中,即类似select count(*) into count1 from checkTmp这种写法。直接写成select * from checkTmp order by expressID肯定会报错的,因为oracle不知道你要select干什么。
select出来的结果要放到变量中去,select ... into ... from ... where ...
i int:=1;begin loop execute immediate 'select SEQ_WCM_RESOURCE.nextval from dual CONNECT BY LEVEL<130000';exit when i=10;i:=i+1;end loop;end;
select SEQ_WCM_RESOURCE.nextval from dual CONNECT BY LEVEL<130000;我写的sql如下declare i int:=1; begin loop select SEQ_WCM_RESOURCE.nextval from dual CONNECT BY LEVEL<130000; exit when i=10; i:=i+1; end loop;end;报了 在此 SELECT 语句中缺少 INTO 子句请问要怎么修改,才能实现...