select sum(zong) from table where unix_timestamp(date) between unix_timestamp('2013-05-05') and unix_timestamp('2013-09-01') group by date;