limit results

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
wystan
Forum Newbie
Posts: 5
Joined: Thu Jun 03, 2004 11:49 am

limit results

Post by wystan »

Im executing a query to a database that returns about 40 rows. How do I limit the results returned so it only shows 5 results at a time. While at the bottom of the page have links for "next 5", "previous 5"

ie.

results:
1-5
6-10
11-16
ect
wystan
Forum Newbie
Posts: 5
Joined: Thu Jun 03, 2004 11:49 am

Post by wystan »

As a follow up: it should work somewhat like the next and previous feature at the bottom of the list of threads
magicrobotmonkey
Forum Regular
Posts: 888
Joined: Sun Mar 21, 2004 1:09 pm
Location: Cambridge, MA

Post by magicrobotmonkey »

wystan
Forum Newbie
Posts: 5
Joined: Thu Jun 03, 2004 11:49 am

Post by wystan »

After working with it for a few minutes I got the code to execute without errors. But, my results are a column with all of my id numbers, and click the button for 'next' give a 'page cannot be found' error.

http://students.ist.psu.edu/~jsf181/ver6/test.txt
Post Reply