Hi All,
I have a problem using the LIMIT statement in MySQL. Basically I want to limit results to a number such as 200. However, this works fine except it returns the *first* 200 records it finds. What I want is the *last* 200 records because I need to examine the latest records.
here's an example of how the query looks now:
SELECT recordid FROM allRecords WHERE userID = $uID ORDER BY recordid LIMIT 0, 200
What do I need to change/add to make it pull the latest records and not the first 200?
Thanks,
Nick
I have a problem using the LIMIT statement in MySQL. Basically I want to limit results to a number such as 200. However, this works fine except it returns the *first* 200 records it finds. What I want is the *last* 200 records because I need to examine the latest records.
here's an example of how the query looks now:
SELECT recordid FROM allRecords WHERE userID = $uID ORDER BY recordid LIMIT 0, 200
What do I need to change/add to make it pull the latest records and not the first 200?
Thanks,
Nick