How can you select the top n max values from a table?
For a table like this:
column1 column2 1 foo 2 foo 3 foo 4
If you are using mySQl, why don't you use the LIMIT functionality? Sort the records in descending order and limit the top n i.e. :
SELECT yourColumnName FROM yourTableName ORDER BY Id desc LIMIT 0,3