Ive got a date picker which passes 2 dates from a form to a PHP script. On that script i have a query for between those 2 dates. The problem i have is that to get todays entry (for example) i have to pick the end date as tomorrow.
$query = "SELECT * FROM clock_status , staff
WHERE auth = 1 and clock_status.user_id = staff.staff_number
and status = 0
and amend_time BETWEEN '$start_date' and '$end_date'";
The $start_date and $end_date are in date only format YYYY-MM-DD (2011-01-26) the date in the DB is YYYY-MM-DD hh:mm:ss.
Any suggestions how to include the whole day in the query.