I needed to know how many users registered during June and July, this is the first query I wrote:
select count(*) from users where created_at>="2013-06-01" and created_at<="2013-07-31"
Result: 15,982
select count(*) from users where year(created_at)=2013 and month(created_at) in (6,7)
Result: 16,278
Why do they return a different result? Could someone explain? Or am I missing something?
Thanks.