I would like to retrive a TODAY’S data from the database, but I don’t know how to do it. I would actually want to get the data from NOT the past 24 hours, I just want today’s data (so based on the actual server time).
I would also like to get data which was yesterday. Can anyone help me how to do it?
Sample code:
"SELECT id FROM folk WHERE time = ???"
Thank you in advance!
I think you are looking for this:
time must be a field in you table that holds a reference to the row.
update
To get yesterdays additions:
update 2
To get all additions this month:
reference: http://dev.mysql.com/doc/refman/5.5/en/date-and-time-functions.html