SET ENGINEBEHAVIOR 70 SELECT coun(姓名) 人数 FROM (SELECT DISTINCT 姓名 FROM a1 WHERE 岗位分类=[A] OR 岗位分类=[C]) a
SELECT 季度,coun(姓名) 人数 FROM (SELECT DISTINCT 姓名,CAST(CEILING(CAST(GETWORDNUM(培训时间,1,[月]) AS N(2))/3) AS N(1)) 季度 FROM 培训记录 WHERE 岗位分类=[A] OR 岗位分类=[C]) a