Categories
How can I get the rows in which the date is in the interval of the past hour?
How can I get the rows in which the date is within an hour? This format: 2017-09-06 07:27:08.
2017-09-06 07:27:08
Answer the question
In order to leave comments, you need to log in
SELECT * FROM foo WHERE date BETWEEN DATE_SUB(NOW(), INTERVAL 1 HOUR) AND NOW()
Didn't find what you were looking for?
Ask a Question
731 491 924 answers to any question