I have a simple MySQL query that selects all columns from the table based off two requirements.
`$dbSearchRecords = mysql_query("SELECT * FROM booking WHERE BookingID = '$JobNo_search' AND Date BETWEEN '$DateFrom_search' AND '$DateTo_search'" )`
I am trying to get the query to search either one or both of the requirements. WHERE BookingID = '$JobNo_search' AND Date BETWEEN '$DateFrom_search' AND '$DateTo_search'
At the moment all parameters need to be present to get a result and I need to be able to search just the BookinID or just the date range as well.
Cheers guys.