mysql select where date is < this month/year |
[eluser]megabyte[/eluser]
I'm sure there a re few ways, but rather than do it thewrong way I thought I'd ask for help. Looking to select from table where results will be older than the current month/year
[eluser]kiedis[/eluser]
Hi, Dates al least one year/month older than current date Code: SELECT mytable.* FROM mytable WHERE my_date_field < DATE_SUB(CURDATE(), INTERVAL 1 YEAR) DATE_SUB function help |
Welcome Guest, Not a member yet? Register Sign In |