mysql中查询时间为空的数据

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了mysql中查询时间为空的数据相关的知识,希望对你有一定的参考价值。

mysql表中datetime类型的字段名createtime,查询所有createtime为空的语句如下:

select * from yy_business where ISNULL(createtime) is TRUE
update yy_business set createtime=‘2015-01-21 17:24:58‘ where ISNULL(createtime) is TRUE

以上是关于mysql中查询时间为空的数据的主要内容,如果未能解决你的问题,请参考以下文章