看你是什么数据库了在oracle中用select * from ywmain where ywblflag is null

解决方案 »

  1.   

    String test=null;
    select * from ywmain where ywblflag='"+test+"';
      

  2.   

    ywblflag为空的话,在数据库里应该是null.
    select * from ywmain where ywblflag is null
      

  3.   

    可能那个ywblflag字段并不是为空,而是为NULL吧,如果那样,这条语句就起不了作用。
      

  4.   

    String test=null;
    select * from ywmain where ywblflag='"+test;
      

  5.   

    select * from ywmain where ywblflag is null
    或是String test=null;
    select * from ywmain where ywblflag='"+test;
    都对的/谢了