DATE FUNCTIONS

From: Date: Wed, 14 Feb 2001 05:54:22 +0000
Subject: DATE FUNCTIONS
Groups: php.db 
Request: Send a blank email to php-db+get-6591@lists.php.net to get a copy of this message
I'm having problems using SQL date functions with ODBC (unix). I've browsed endless mailing lists and manuals but things that seem to work for other people doesn't work on my setup. I can get my IF statement in php working, but really need to have the validation in the select statement. Other date functions like WEEKDAY() doesn't work either. My statements are something like select * from menuyr where meal_dte = DATE("02/15/2001") and select * from menuyr where WEEKDAY(meal_dte) = 2 They both give the same error: Warning: SQL error: [unixODBC][OpenLink][ODBC][Driver]Option Value Changed, SQL state [Ã÷Ø in SQLExecDirect in /www/data/isdmeals/ru_diet.php on line 73 Line 73 would be the odbc_exec() statement. Am I doing something totally stupid or is their some kind of library to be included for these functions to work? Oh, and another thing is if I run the exact same select statement on the database directly - it works! Hope someone can help... Lynnette Klackers

« previous php.db (#6591) next »