MSSQL code for sales distribution report by hour
My MSSQL code that generates reports from the FATBASLIK table by time ranges. select TARIH=(convert(VARCHAR(10),FB.TARIH,120)), '_09'=(select SUM(FATURA_TUTARI) from FATBASLIK FB1 where FB1.TARIH BETWEEN convert(VARCHAR(10),FB.TARIH,120)+' 08:59:00.000' AND convert(VARCHAR(10),FB.TARIH,120)+' 09:59:00.000' ), '_10'=(select…