Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id 9CED5B5D803 for ; Fri, 17 Jun 2011 21:46:51 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 09311-09 for ; Sat, 18 Jun 2011 00:46:45 +0000 (UTC) X-Greylist: delayed 00:32:31.77122 by SQLgrey-1.7.6 Received: from bosmailout11.eigbox.net (bosmailout11.eigbox.net [66.96.189.11]) by mail.postgresql.org (Postfix) with ESMTP id 9C05BB5DBDE for ; Fri, 17 Jun 2011 21:46:45 -0300 (ADT) Received: from bosmailscan19.eigbox.net ([10.20.15.19]) by bosmailout11.eigbox.net with esmtp (Exim) id 1QXihY-00044C-Sl for pgsql-sql@postgresql.org; Fri, 17 Jun 2011 19:43:48 -0400 Received: from bosimpout02.eigbox.net ([10.20.55.2]) by bosmailscan19.eigbox.net with esmtp (Exim) id 1QXihW-0001OU-VX for pgsql-sql@postgresql.org; Fri, 17 Jun 2011 19:43:46 -0400 Received: from bosauthsmtp05.eigbox.net ([10.20.18.5]) by bosimpout02.eigbox.net with NO UCE id xBjn1g00A06Zqne01Bjnsv; Fri, 17 Jun 2011 19:43:47 -0400 X-EN-OrigOutIP: 10.20.18.5 X-EN-IMPSID: xBjn1g00A06Zqne01Bjnsv Received: from [41.233.117.156] (helo=localhost.localdomain) by bosauthsmtp05.eigbox.net with esmtpsa (TLSv1:AES256-SHA:256) (Exim) id 1QXihX-0007FM-7s for pgsql-sql@postgresql.org; Fri, 17 Jun 2011 19:43:47 -0400 Message-ID: <4DFBD8A0.9000503@softpro.bz> Date: Sat, 18 Jun 2011 01:43:44 +0300 From: hatem gamal elzanaty User-Agent: Thunderbird 2.0.0.24 (X11/20101213) MIME-Version: 1.0 To: pgsql-sql@postgresql.org Subject: pagination problem in postgresql need help Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-EN-UserInfo: 9f6d45284487177df345665b293cfcf1:bf72d2e9cad2176c82d6320258861423 X-EN-AuthUser: hatem@softpro.bz X-EN-OrigIP: 41.233.117.156 X-EN-OrigHost: unknown X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.91 tagged_above=-5 required=5 tests=BAYES_00=-1.9, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201106/63 X-Sequence-Number: 35529 hi, please see this code select aiah_number.aiah_number_id, aiah_number.aiah_number, lock.lock_status, rank.rank_value, approve.approve_status, lock.view from aiah_number inner join lock on aiah_number.locked = lock.lock_id inner join rank on aiah_number.rank = rank.rank_id inner join approve on aiah_number.approve = approve.approve_id order by rank_value desc limit 1 offset 0; and this code select aiah_number.aiah_number_id, aiah_number.aiah_number, lock.lock_status, rank.rank_value, approve.approve_status, lock.view from aiah_number inner join lock on aiah_number.locked = lock.lock_id inner join rank on aiah_number.rank = rank.rank_id inner join approve on aiah_number.approve = approve.approve_id order by rank_value desc limit 1 offset 1; suppose i have 200 hundred record and i want to display records in pages one record per page i'm facing a problem even if i'm running the script through phppgadmin it's only display the first record in the page only no more no less in the php code it display record 1 and records byound 180 and so on can you help in that issue ? thanks in advance