select 字段 from(select 字段,case when to_char(operation_date,'hh24:mi:ss')<to_char(sysdate,'hh24:mi:ss') then operation+1 else operation end opdate from sdjc order by opdate) where rownum<=4;

解决方案 »

  1.   

    select 字段 from(select 字段,case when to_char(operation_date,'hh24:mi:ss')<to_char(sysdate,'hh24:mi:ss') then operation_date+1 else operation_date end opdate from sdjc order by opdate) where rownum<=4;
      

  2.   

    select sta,flight_no,code_share1,code_share2,code_share3,
    code_share4, origin_city_chinese,eta,abnormal_status 
    from sdjc where d_or_I=’D’ and a_or_d =’A’ and rownum<4 order by abs(operation_date-now);