论坛首页 Java企业应用论坛

oracle中continue的实现方法

浏览 1485 次
精华帖 (0) :: 良好帖 (0) :: 新手帖 (0) :: 隐藏帖 (0)
作者 正文
   发表时间:2012-02-07  

1.使用GOTO

例:

for REC in CUR loop

 

if CONDITION then

    goto BREAKPOINT;

end if;

 

<<BREAKPOINT>>

NULL;

end loop;

 

注意NULL必须有;

 

2.使用EXCEPTION

例:

for REC in CUR loop

 

begin 

  if CONDITION then

      raise myexception;

  end if;

exception

  when myexception then

     NULL;

end;

 

end loop;

论坛首页 Java企业应用版

跳转论坛:
Global site tag (gtag.js) - Google Analytics