mattsolomon Posted March 6, 2011 Share Posted March 6, 2011 if i want to display upcoming events and only want to show the top 3? Link to comment https://forums.phpfreaks.com/topic/229817-how-can-i-limit-the-amount-of-queries-returned/ Share on other sites More sharing options...
redarrow Posted March 6, 2011 Share Posted March 6, 2011 SELECT * FROM `your_table` LIMIT 0, 3 Link to comment https://forums.phpfreaks.com/topic/229817-how-can-i-limit-the-amount-of-queries-returned/#findComment-1183756 Share on other sites More sharing options...
mattsolomon Posted March 6, 2011 Author Share Posted March 6, 2011 thank you, does that come before or after the ORDER function? Link to comment https://forums.phpfreaks.com/topic/229817-how-can-i-limit-the-amount-of-queries-returned/#findComment-1183760 Share on other sites More sharing options...
brentmoeller Posted March 6, 2011 Share Posted March 6, 2011 SELECT table from table ORDER BY last DESC LIMIT 3; of course altering table table last Link to comment https://forums.phpfreaks.com/topic/229817-how-can-i-limit-the-amount-of-queries-returned/#findComment-1183761 Share on other sites More sharing options...
mattsolomon Posted March 7, 2011 Author Share Posted March 7, 2011 Thanks a bunch x Link to comment https://forums.phpfreaks.com/topic/229817-how-can-i-limit-the-amount-of-queries-returned/#findComment-1183766 Share on other sites More sharing options...
brentmoeller Posted March 7, 2011 Share Posted March 7, 2011 do you got it figured out matt? Link to comment https://forums.phpfreaks.com/topic/229817-how-can-i-limit-the-amount-of-queries-returned/#findComment-1183768 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.