select IFNULL(‘可能有空值的列’,‘为空值时默认的值(数据类型记得对上)’) from table 例;
SELECT IFNULL(zt,0),dctm FROM tb_battery_old_table