当前位置: 代码迷 >> MySQL >> MySQL里边值为NULL的判断
  详细解决方案

MySQL里边值为NULL的判断

热度:91   发布时间:2016-05-05 16:58:43.0
MySQL里面值为NULL的判断

?

select t.args1,t.args2,t.args3 from beyond t ;

?

?

?

select  t.args1,t.args2,t.args3 from beyond t where t.args2 != null ;


?

这种情况竟然查出来是 Null ,没有报错!

?

select  t.args1,t.args2,t.args3 from beyond t where t.args2 != 'null' 

?


?

?

注: 用 mysql 的 null 做判断的时候,需谨慎!

?

?

  相关解决方案