X-Original-To: pgsql-php-postgresql.org@postgresql.org Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id 6F41B9FB3E7 for ; Thu, 31 Aug 2006 12:57:33 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 06802-03-6 for ; Thu, 31 Aug 2006 12:57:18 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from tetra.ehpg.net (tetra2.ehpg.net [65.19.161.8]) by postgresql.org (Postfix) with ESMTP id 79D7B9FB3F6 for ; Thu, 31 Aug 2006 12:55:17 -0300 (ADT) Received: from adsl-68-120-81-107.dsl.irvnca.pacbell.net ([68.120.81.107] helo=[172.16.1.36]) by tetra.ehpg.net with esmtpa (Exim 4.60) (envelope-from ) id 1GIost-0000AT-9k; Thu, 31 Aug 2006 08:55:15 -0700 In-Reply-To: <20060831074206.42370.qmail@web55205.mail.re4.yahoo.com> References: <20060831074206.42370.qmail@web55205.mail.re4.yahoo.com> Mime-Version: 1.0 (Apple Message framework v752.2) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <5807B3E2-F486-47CB-B8AB-5D20ABD6FD65@ehpg.net> Cc: pgsql-php@postgresql.org Content-Transfer-Encoding: 7bit From: "Gavin M. Roy" Subject: Re: Postgres 8.1.4 + PHP, hangs when querying more than 16 records! Date: Thu, 31 Aug 2006 08:55:01 -0700 To: babak badaei X-Mailer: Apple Mail (2.752.2) X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.041 tagged_above=0 required=5 tests=AWL, SPF_PASS X-Spam-Level: X-Archive-Number: 200608/22 X-Sequence-Number: 3593 Have you tried with pdo? $pdo = new PDO('pgsql:host=localhost;dbname=database','web'); $query = $pdo->query('SELECT * FROM foobar;'); $query->execute(); $data = $query->fetchAll(PDO::FETCH_OBJ); print_r($data); And have you tried not using other peoples packages but downloading the source and compiling it? I run PHP 5.1.4 and work with very large data sets, though I've not upgraded to 5.1.6 yet. Hope this helps, Gavin On Aug 31, 2006, at 12:42 AM, babak badaei wrote: > Hi Chris, Run through the native client everything works fine. I > know, its really strange. Any ideas? > > ----- Original Message ---- > From: Chris > To: babak badaei > Cc: pgsql-php@postgresql.org > Sent: Wednesday, August 30, 2006 11:42:01 PM > Subject: Re: [PHP] Postgres 8.1.4 + PHP, hangs when querying more > than 16 records! > > babak badaei wrote: >> OS: Fedora Core 5 >> PHP: PHP 5.1.4, PHP 5.1.6, and PHP 4.4.4 (compiled with --with- >> pgsql and install as binaries using YUM) >> Postgres 8.1.4 >> >> This scripts works: >> --------------------------------------------------------------------- >> ------------ >> > // Connecting, selecting database >> $dbconn = pg_connect("host=localhost dbname=database user=web") >> or die('Could not connect: ' . pg_last_error()); >> >> // Performing SQL query >> $query = 'SELECT * FROM foobar limit 16'; > > > >> // Performing SQL query >> $query = 'SELECT * FROM foobar limit 17'; > > That seems really weird. > > If you run those through psql natively what happens? > > -- > Postgresql & php tutorials > http://www.designmagick.com/ > > > > > ---------------------------(end of > broadcast)--------------------------- > TIP 6: explain analyze is your friend