1.
if b<>0 and a/b>0 then
end if;2. select decode(b,0,0,a/b) into c from dual;
   if c > 0 then
   end if;

解决方案 »

  1.   


       。
       。
     c := a/b;
       。
       。
       。exception
       when others then
           begin
            c := 0;
           end;
      

  2.   

    其实我是需要做解析,将某些文档解析成proc。
    比较难于确定a,b
    最好有类似nvl(a,0)之类的
    hepp,你的那种情况,不能返回往下执行哦,可以根据errcode判断,但无法继续往下执行!
    而且客户要求类似decode(b,0,0,b/a)这种结果。
      

  3.   

    对了,a/b大于零,其实不就是a*b>0吗?这样不就没有除零的烦恼了?