I tried putting in the field in there, but I still get no result back. I know for a fact I have some in that range too. Here is my code:
$from = "$fr_year-$fr_month-$fr_date";
$to = "$to_year-$to_month-$to_date";
$sql = "SELECT customer, date_expected, amount, contracts, date_recd, amount_recd FROM check_forecast WHERE date_expected BETWEEN $from AND $to ORDER BY customer";
$result = mysql_query($sql);
if(!$result) { echo mysql_error(); exit(); }
The field date_expected is in the mysql date format, YYYY-MM-DD. Before this page, a user selects the dates in the drop down format, first by month, date, and year. So I made it format the values in the mysql date format.
Any suggestions?
Thanks in advance,