SQL查询CASE遇上NULL怎么办?

原SQL: case userName when  null THEN '空' else '有值' end, 这种写法不好使;

换一种:case when userName is null THEN '空' else '有值' end,这种写法好使;

打赏
原文地址:https://www.cnblogs.com/yanshaoxiong/p/11469006.html