分组求行数
SELECT DateTime,AgentName ,Count(SessionId)as DayWorkSum ,1 as DayWork FROM cti_record WHERE Date ='2012-03-04' and AgentName in (1006,1013 )group by AgentName