您好,我很难将这个查询转换为T-SQL,我将感谢任何帮助
TRANSFORM Sum(ViewMaster.ServiceCount) AS SumOfServiceCount
SELECT ViewMaster.Response, Sum(ViewMaster.ServiceCount) AS [Total Of ServiceCount]
FROM ViewMaster
GROUP BY ViewMaster.Response
PIVOT ViewMaster.Month;
SELECT *
FROM ( SELECT Response, ServiceCount, Month
FROM ViewMaster) VM
PIVOT(SUM(ServiceCount) FOR Month IN ('January','February',...,'December'))