oakes6b2 Posted March 3, 2007 Share Posted March 3, 2007 What would be the best way to filter a MySQL recordset to show only the last 6 months? I am a pilot and I have a db that has my flight information and I want to display how many instrument approaches I have done in the last 6 months! Thanks in advance. Oops...wrong forum. Please move Quote Link to comment Share on other sites More sharing options...
fenway Posted March 4, 2007 Share Posted March 4, 2007 Add this to your WHERE clause: yourDateField >= NOW() - INTERVAL 6 MONTH Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.