
select count(*) 为什么返回null值而不是0,什么情况返回null
查询语句:selectcount(*)fromTabletwheret.c1='1'groupbyt.c1,t.c2...
查询语句:select count(*) from Table t where t.c1='1' group by t.c1,t.c2
展开
展开全部
没有满足的条件记录就是null
要返回0需要转换
select nvl(count(*),0) from table
要返回0需要转换
select nvl(count(*),0) from table
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询