If you look at the dates, today is the 14th, and I am asking for the whole month report,
Its missing TODAY…
look at the dates and todays date, and I asked for the month:fevereiro interval
STRANGE behaviour… look at the upper left combo with dates, on the first screens you will see that january has 30 days… and then in the last screen you will see that january has 31 days…
Hmm… It weird I get that as well. It look like in report query use start of the work period on both start and end range. The end range should be end of work period. When I select This Month, it report Feb 1, 2016 11:12 to Feb 14, 2016 16:29 (Start of work period).
Have you updated, this might be related to the fate issue I mentioned where if ends was after midnight and distinguishing.
If you set first of Feb did it also include 1st figures?
[Ventas Dia a Dia:3,3, 2, 2, 2, 2]
>Fecha|Dia|Neto|Taxa|Desc|Total
@@VentasDiarias
>TOTAL||@@TotalVentasDiarias
SELECT
convert(nvarchar,T.Date,103) as Fecha,
min(datename(dw,Date)) as Dia,
FORMAT(ISNULL(SUM(T.TotalAmount)-SUM(Cal.CalculationAmount),0),'C') as NetoTicket,
FORMAT(SUM(case
when Cal.CalculationTypeId = 3 then Cal.CalculationAmount
else 0 end),'C') as Taxa,
FORMAT(SUM(case
when Cal.CalculationTypeId = 1 then Cal.CalculationAmount
else 0 end),'C') as Desconto,
FORMAT(SUM(T.TotalAmount),'C') as TotalTicket
FROM Tickets AS T
LEFT OUTER JOIN Calculations as Cal on Cal.TicketId = T.Id
WHERE Date >= '{Start}' AND Date <= '{End}'
GROUP BY convert(nvarchar,T.Date,103)
ORDER BY min(T.Date)
SELECT
FORMAT(ISNULL(SUM(T.TotalAmount)-SUM(Cal.CalculationAmount),0),'C') as NetoTicket,
FORMAT(SUM(case
when Cal.CalculationTypeId = 3 then Cal.CalculationAmount
else 0 end),'C') as Taxa,
FORMAT(SUM(case
when Cal.CalculationTypeId = 1 then Cal.CalculationAmount
else 0 end),'C') as Desconto,
FORMAT(SUM(T.TotalAmount),'C') as TotalTicket
FROM Tickets AS T
LEFT OUTER JOIN Calculations as Cal on Cal.TicketId = T.Id
WHERE Date >= '{Start}' AND Date <= '{End}'