use adventureworks2012 go ;with TempCTE as ( select sm.Name as ShipName, DatePart(q,OrderDate) as QtrNum, sum(TotalDue) as TotDue from Purchasing.PurchaseOrderHeader POH join Purchasing.ShipMethod SM on POH.ShipMethodID = sm.ShipMethodID where year(OrderDate) = 2008 group by SM.Name, datepart(q, orderDate) ) select ShipName, [1] as Q1, [2] as Q2, [3] as Q3 , [4] as Q4 from TempCTE PIVOT ( SUM(TotDue) for QtrNum in ( [1], [2], [3], [4])) TempNow, you've got an added twist - you want to have multiple aggregations (a count and a sum) for each month being spread across the columns. There are different ways you can do it - I've seen people use combinations of CROSS APPLY and other language features with PIVOT.