select <fields list> from <db.table> where <date_field> > date_sub(curdate(), interval 3 month);
give that a shot On 6/9/05, Graeme McLaren <[EMAIL PROTECTED]> wrote: > Hi all, wondering if anyone can help me out with a mysql query (bit off > topic I know) > > select id, title, DATE_FORMAT(auto_enter_date, '%D %b %Y') as date from dci > where auto_enter_date > between ((DATE_SUB(CURDATE(), INTERVAL 90 DAY) and DATE_FORMAT(CURDATE, '%D > %b %Y')); > > > I want to select the id, title and date between now and the last 3 months, > can anyone show me the correct SQL? > > > Cheers in advance, > > Graeme :) > > > > -- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > <http://learn.perl.org/> <http://learn.perl.org/first-response> > > > -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>