hello, i have a table with a DATETIME column... I want to do a SELECT of all records from a specific month of the year. So something like with this pseudo code: SELECT * FROM table WHERE datecolumn = OCTOBER 2006
To return results for anything from October (Oct '04, '05, or '06)... SELECT * FROM table WHERE MONTH(datecolumn) = 10 Code (markup): To return results for October of 2006: SELECT * FROM table WHERE MONTH(datecolumn) = 10 AND YEAR(datecolumn) = 2006 Code (markup): http://dev.mysql.com/doc/refman/5.0/en/date-and-time-functions.html