set @report_date = '2013-01-17 00:00:00'; SELECT * FROM `NMPP`.`capacitypersecond` WHERE `StreamDT` >= @report_date and `StreamDT` < '2013-01-18 00:00:00' ;