SELECT  YEAR(F.TARIH) AS YIL,MONTH(F.TARIH) AS AY, F.TARIH, F.DEPT as 'DepartmanKodu', D.ADI as 'DepartmanAcıklama', SUM(F.BORC) AS TUTAR
FROM FOLYOISL AS F INNER JOIN
 DEPART AS D ON D.KODU = F.DEPT
 WHERE D.TUR='A' and F.DEPT<>'92'
GROUP BY YEAR(F.TARIH),MONTH(F.TARIH), F.TARIH, F.DEPT, D.ADI
ORDER BY 1,2,3 ASC