Retrieving search queries in pages

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
dafinch
Forum Commoner
Posts: 25
Joined: Wed Jun 06, 2007 10:34 am

Retrieving search queries in pages

Post by dafinch »

I'm writing a web page in php that searches a mysql database that contains some log information. I've got the sql queries working exactly how I want them. The issue I currently have is that as the database gets larger the data thats being returned is getting quite big and the searches are taking longer. What I would like to implement is returning the queries in pages (say 50 or 100 log entries on a page). At first I thought I would read the query into an array and display it in pages but thats not buying me a lot and I believe there has to be a better way. I would appreciate any suggestions or tips that would point me in the right direction on this.

Thanks
User avatar
volka
DevNet Evangelist
Posts: 8391
Joined: Tue May 07, 2002 9:48 am
Location: Berlin, ger

Post by volka »

Strange enough there's no tutorial in this board's tutorial forum about pagination.
But you can find plenty of them via google. http://www.google.de/search?hl=en&q=pag ... tnG=Search
dafinch
Forum Commoner
Posts: 25
Joined: Wed Jun 06, 2007 10:34 am

Post by dafinch »

Many thanks. Thats exactly what I'm looking for.
User avatar
volka
DevNet Evangelist
Posts: 8391
Joined: Tue May 07, 2002 9:48 am
Location: Berlin, ger

Post by volka »

Hopefully ou will pick a good one ;)
Post Reply