date name 2007 kk 2007 dd 2009 zd 2010 jack 2010 tom
ÎÒÏëµÃµ½²»Í¬µÄÄê·ÝµÄ¸öÊý select [date],count(name) from tableName group by [date] select date , count(1) from tb group by date ÎÒÒªµÄ²»ÊÇÿ¸ödate³öÏֵĸöÊý£¬¶øÊDz»Í¬dateµÄ¸öÊý select count(*) as sl from (select [date] from tableName group by [date]) SQL code: select count(*) from (select distinct [date] from table1)