I want to run a query where you select every data between date1 to date2 that has status of Confirmed or Reserved grouped by status.
But the code I'm trying,
select * from reservation where (date(bdate) between '2013-2-4' and '2013-2-8') and status='Reserved' or status='Confirmed' order by status
doesn't seem to work.
I need to fetch the data within the date range only that has either Confirmed or Reserved status. Please help me. Thanks.