为什么报下面的错误啊?update t_c_3_pyjd set pyzdh=34 where pyzt in ('03')  rownum<5
minus
update t_c_3pyjd set pyzdh=34 where pyzt in ('03')  rownum<2;
为啥不行啊ORA-00933: SQL command not properly ended

解决方案 »

  1.   

    in没有什么错误啊,
    select * from t_c_3pyjd  where pyzt in ('03')  rownum<5
    minus
    select * from t_c_3pyjd where pyzt in ('03')  rownum<2;  
    可以阿!
      

  2.   

    update t_c_3_pyjd set pyzdh=34 where pyzt ='03' and  rownum<36
    minus
    update t_c_3_pyjd set pyzdh=34 where pyzt='03' and   rownum<2;
    刚才忘写and了,但是加上以后还是那个错误!
      

  3.   

    update 能 minus 吗?
      

  4.   

    in没有什么错误啊,
    select * from t_c_3pyjd  where pyzt in ('03')  rownum<5
    minus
    select * from t_c_3pyjd where pyzt in ('03')  rownum<2;  
    可以阿!
    <<<<<<<<<<<<<<<<<<<<
    你确定这样可以?你用的是什么数据库工具?我用的是pl/sql 7.0也会报同样的错误。我在
    where 的两个条件之间加了 and 就可以了
    ===================================
    select * from t_c_3pyjd  where pyzt in ('03') and rownum<5
    minus
    select * from t_c_3pyjd where pyzt in ('03') and rownum<2;