select count(*) from yourtableif count(*)>0 then exist records!

解决方案 »

  1.   

    declare
    num number;
    begin
    select count(1) into num from table_name;
    if num>0 then
    ...
    end if;
    end;
    /
      

  2.   

    select count(*) into a_variable from yourtable
      

  3.   

    如果用proc,判断sqlcode的值是否等于100
    如果是别的高级语言,判断recordcount的值
    如果是sqlplus,直接看结果
    0 rows deleted
      

  4.   

    select count(被设为主銉的字段) into a_variable from yourtable