It produces this (truncated to include the important data only) :
day | sum_id
------------------------------"2014-07-07 00:00:00"|1898.84
So looking for same date using different date range I get different results, how is this even possible? Can I look at something else? I'm really stuck here
Thanks
Remove the sum (just select "payments.amount") and the GROUP BY and run your queries. You'll see that you're getting different rows included than you think you are.
--
I asked the Internet how to train my cat, and the Internet told me to get a dog.