i want to ask, how to count date row when data is null using aqua data studio.
For example
select
convert(varchar(10),dateclosed,103)
from customer
where dateclosed = '(null)'
no. dateclosed count(dateclosed)
1 1/1/2001 2
2. 1/1/2001
3. 2/1/2001 1
4. 3/1/2001 1
5. (null) 4
6. (null)
8. (null)
9. (null)
10. 5/1/2001 3
11. 5/1/2001
12. 5/1/2001
13. 6/1/2001 1
The aggregate functions (except for
COUNT(*)) ignore the NULL values, so you need to:COUNT(*)(instead ofCOUNT(expression))OR
convert all the NULL values to some characteristic date: