sql函数中有没有这样的函数,如果字段大于0的则返回一个0.就是把大于0的变成0.

2025-04-24 08:41:34
推荐回答(1个)
回答1:

case when就行
select case when 字段名>0 then 0 else 字段名 end from 表名