I’ve a table called graphs and it has my fields like:
id, name, channel, created.. etc. created field is DATETIME.
Now, I want to retrieve data with one minute time interval. That is, date difference with current time and created field will be one minute.
Here created field date format is: Y-m-d h:i:s.
What is the solution? Please help.
use this query
http://dev.mysql.com/doc/refman/5.5/en/date-and-time-functions.html