select sum(case when date1 is not null then 1 else 0 end),sum(case when date2 is not null then 1 else 0 end),sum(case when date3 is not null then 1 else 0 end)
from table
from table
解决方案 »
- 求一条SQL 语句,要求最简单的实现!
- 如何按比例生成数据
- 请帮我修改一条SQL语句:使统计的结果由0.6522222222变成65.22%
- 晕,没分了. 问最后一下,SQL Server 编码规范问题.
- 100分向高手求解:一个sql自定义函数的奇怪问题
- IE不能正常访问本机的SSRS Server
- 求个sql语句
- job 与proc的现实问题 高手来看
- Sql 行合并 (没有id列)
- SQL Server 7.0 数据库恢复问题
- 请问什么原因导致“System.Data.SqlClient.SqlException: 将截断字符串或二进制数据。”异常??谢谢!!
- 怎样将txt文件导入sql数据库
,(select count(*) from T where date2 is not null)
,(select count(*) from T where date3 is not null)