RE: [PHP-DB] select date YYYY-MM mysql help

From: Date: Thu, 02 Jan 2003 22:38:42 +0000
Subject: RE: [PHP-DB] select date YYYY-MM mysql help
Groups: php.db 
Request: Send a blank email to php-db+get-24500@lists.php.net to get a copy of this message
Sounds more like an SQL question than PHP, but try the following: SELECT * FROM table WHERE date LIKE '2002-12%'; Regards, Matthew Moldvan --------------------------------------- System Administrator Trilogy International, Inc http://www.trilogyintl.com/ecommerce/ --------------------------------------- -----Original Message----- From: Max Clark [mailto:max@clarksys.com] Sent: Thursday, January 02, 2003 5:40 PM To: php-db@lists.php.net Subject: [PHP-DB] select date YYYY-MM mysql help Hi all, I would like to do a query like this from mysql: select * from table where date = '2002-12'; However unless I have the complete date '2002-12-26' the query doesn't work correctly. What else do I need? Thanks in advance, Max -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

« previous php.db (#24500) next »