Hi.
I’m fairly new to both MySQL and PHP, but finding it interesting. I’ve been working on a project that passes variables across the URL from one page to another and then uses the passed parameter to filter a query. This all works fine with Integer values.
So I can’t understand why I can’t do this with a date. Through trial and error and a lot of reading I know the problem is not with the passing of the date, but how I reference it in the query.
In the example I’ve replaced the returned value with the date in $pass_date, this is then used in the query, which never results in any data being found.
If I move the actual string ‘200-03-11’ into the query in place of the $pass_date then the expected result occurs and a extract the data I’m looking for.
As I said I’ve used the same syntax to query many integer values with no problem.
If you can help I’d be most appreciative.