List:General Discussion« Previous MessageNext Message »
From:Patrick Sherrill Date:May 20 1999 6:04pm
Subject:Re: retrieving the last 20 rows
View as plain text  
SELECT * from TABLE ORDER BY timestampField DESC LIMIT 20;

-----Original Message-----
From: mab@stripped <mab@stripped>
To: MYSQL Mailing List <mysql@stripped>
Date: Thursday, May 20, 1999 1:38 PM
Subject: retrieving the last 20 rows

>I have a table with a timestamp(10) column and an auto-increment
>I want to know the most efficient way to retrieve the last
>20 records (by date) in the table which have either been inserted/updated.
>Thanks in advance,
>Please check "" before
>posting. To request this thread, e-mail mysql-thread3647@stripped
>To unsubscribe, send a message to the address shown in the
>List-Unsubscribe header of this message. If you cannot see it,
>e-mail mysql-unsubscribe@stripped instead.

retrieving the last 20 rowsmab20 May
Re: retrieving the last 20 rowsPatrick Sherrill20 May