MySQL - Select most recent date out of a set of several possible timestamps?

Viewed 41283

I would like to know if this is possible using a mysql query:

I have a table called updates.

In the updates table I have 2 columns, id and timestamp.

I have 5 rows each with the same id but with different date timestamps. An example of this timestamp would be the value: 2012-08-04 23:14:09.

I would like to select only the most recent timestamp value out of the 5 results. This could also be explained by saying that I would like to select the value that is closest to the current date and time. How could I do this?

2 Answers
Related