Logic question

From: Date: Wed, 17 Apr 2002 15:43:55 +0000
Subject: Logic question
Groups: php.general 
Request: Send a blank email to php-general+get-93341@lists.php.net to get a copy of this message
I am running the following SQL query which is returning a list of about 100 entries. The entries are sorted numerically by image_id, but the numbers in image_id are not sequential. For example a return might look like this. 97 54 53 43 32 31 21 $query = "select * from galleries, images where galleries.gallery = '$gallery' and images.gallery_id = galleries.gallery_id and images.image_id >= $offset - 3 and images.image_id < $offset order by images.image_id desc"; What I am trying to do is print out the first 3 rows on one page, and when the visitor hits next I want to be able to display the next 3, and so on. Does anyone have any ideas on how to do this? Mike Fifield Charles Schwab & Co, Inc. WARNING: All e-mail sent to or from this address will be received by the Charles Schwab corporate e-mail system and is subject to archival and review by someone other than the recipient.

« previous php.general (#93341) next »