Arkadaşlar olmuyor,
SELECT LG_707_CLCARD.CODE AS 'M.NO', LG_707_CLCARD.DEFINITION_ AS 'UNVAN', LG_707_01_CLFLINE.TRCODE AS 'TÜR', LG_707_01_CLFLINE.DATE_ AS 'İŞLEM TARİHİ', Sum(LG_707_01_CLFLINE.AMOUNT) AS 'TUTAR', LG_707_01_CLFLINE.BRANCH AS 'İŞYERİ', LG_707_01_CLFLINE.CANCELLED, LG_707_01_CLFLINE.SPECODE AS 'RUT', LG_707_01_CLFLINE.DOCODE AS 'BELGE NO', LG_707_01_CLFLINE.LINEEXP AS 'CSBELGE NO'
FROM UNITY.dbo.LG_707_01_CLFLINE LG_707_01_CLFLINE, UNITY.dbo.LG_707_CLCARD LG_707_CLCARD
WHERE LG_707_CLCARD.LOGICALREF = LG_707_01_CLFLINE.CLIENTREF
GROUP BY LG_707_CLCARD.CODE, LG_707_CLCARD.DEFINITION_, LG_707_01_CLFLINE.TRCODE, LG_707_01_CLFLINE.DATE_, LG_707_01_CLFLINE.BRANCH, LG_707_01_CLFLINE.CANCELLED, LG_707_01_CLFLINE.SPECODE, LG_707_01_CLFLINE.DOCODE, LG_707_01_CLFLINE.LINEEXP
HAVING (LG_707_01_CLFLINE.BRANCH=465) AND (LG_707_01_CLFLINE.TRCODE In (1,61,62,70)) AND (LG_707_01_CLFLINE.CANCELLED=0) AND (LG_707_CLCARD.CODE Like '0%') AND (LG_707_01_CLFLINE.DATE_=GETDATE())
ORDER BY LG_707_01_CLFLINE.DATE_ DESC
Yazdım olmadı, hiç bişe gelmedi.