seventheyejosh Posted January 2, 2009 Share Posted January 2, 2009 My question is, if i have an sqldatabase full of timestamps, how can i display only the chosen month's timestamps? like if i choose dec 2008, how do i make my query pull all rows with a timestamp that has dec 2008? Thanks in advance. Quote Link to comment https://forums.phpfreaks.com/topic/139153-comparing-dates-using-stored-timestamps/ Share on other sites More sharing options...
fenway Posted January 2, 2009 Share Posted January 2, 2009 You can use: WHERE EXTRACT( YEAR_MONTH FROM_UNIXTIME( yourTSColumn) ) = '200812' Quote Link to comment https://forums.phpfreaks.com/topic/139153-comparing-dates-using-stored-timestamps/#findComment-727877 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.