mysql查询字段为null 返回0

SELECT   IF(AVG(字段) IS NULL,0, 字段) as 重命名   From  xxx

猜你喜欢

转载自blog.csdn.net/qq_29072049/article/details/83067882