Jump to content

Limit


rockinaway

Recommended Posts

I have a MYSQL Limit statement that simply uses 'LIMIT 10' at the end. This gets the latest information using a 'WHERE time < '.$current_time.''

 

However, if there aren't another 10 rows to return from the database, it fails to return any rows.

 

How can I limit it to a max of 10 rows but still to return rows if there are less than 10?

Link to comment
https://forums.phpfreaks.com/topic/254327-limit/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.