mysql ifnull,isnull,nullif

 EXTRACT(year from colunm) as year

ifnull(exp1,exp2) 如果exp1不为null 返回exp1 否则返回exp2

isnull(null) 返回1 否则返回零

nullif(exp1,exp2) 如果他俩相等 返回null 否则返回exp1

发表评论

您的电子邮箱地址不会被公开。 必填项已用*标注