Received: from localhost (maia-1.hub.org [200.46.204.191]) by postgresql.org (Postfix) with ESMTP id 539AC9FB286 for ; Mon, 12 Feb 2007 03:06:30 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.191]) (amavisd-new, port 10024) with ESMTP id 69486-04 for ; Mon, 12 Feb 2007 03:06:26 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from rehuapila.uta.fi (rehuapila.uta.fi [153.1.1.45]) by postgresql.org (Postfix) with ESMTP id 248C89FB3F8 for ; Mon, 12 Feb 2007 03:06:25 -0400 (AST) Received: from neliapila.uta.fi (neliapila.uta.fi [153.1.1.43]) by rehuapila.uta.fi (8.13.8/8.13.8) with ESMTP id l1C6woWC012975; Mon, 12 Feb 2007 08:58:50 +0200 (EET) Received: from apila.uta.fi (localhost.localdomain [127.0.0.1]) by neliapila.uta.fi (8.13.8/8.13.8) with ESMTP id l1C6wntM031079; Mon, 12 Feb 2007 08:58:49 +0200 Received: from peippi.uta.fi (peippi.uta.fi [153.1.6.44]) by apila.uta.fi (8.13.8/8.13.8) with ESMTP id l1C6wn80011169 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Mon, 12 Feb 2007 08:58:49 +0200 (EET) Received: from peippi.uta.fi (localhost.localdomain [127.0.0.1]) by peippi.uta.fi (8.13.4/8.13.4/Debian-3sarge3) with ESMTP id l1C6wnji007795; Mon, 12 Feb 2007 08:58:49 +0200 Received: (from wwwroot@localhost) by peippi.uta.fi (8.13.4/8.13.4/Submit) id l1C6wnx7007794; Mon, 12 Feb 2007 08:58:49 +0200 Received: from kielitranpc59.uta.fi (kielitranpc59.uta.fi [153.1.35.59]) by imp2.uta.fi (Horde MIME library) with HTTP; Mon, 12 Feb 2007 08:58:49 +0200 Message-ID: <20070212085849.ts11j575tg6s84o4@imp2.uta.fi> Date: Mon, 12 Feb 2007 08:58:49 +0200 From: Mihail Mihailov To: Michael Fuhr Cc: Mihail Mihailov , pgsql-php@postgresql.org Subject: Re: phpinfo(): postgresql versions' mismatch References: <20070209113129.he36qgs4vthc0o4c@imp3.uta.fi> <20070209145731.GA28879@winnie.fuhr.org> <20070209195346.qlm86chc1u88g84g@imp1.uta.fi> <20070212031352.GA11669@winnie.fuhr.org> In-Reply-To: <20070212031352.GA11669@winnie.fuhr.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; DelSp="Yes"; format="flowed" Content-Disposition: inline Content-Transfer-Encoding: quoted-printable User-Agent: Internet Messaging Program (IMP) H3 (4.1.4-cvs) X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-3.0 (apila.uta.fi [153.1.1.41]); Mon, 12 Feb 2007 08:58:49 +0200 (EET) X-Scanned-By: MIMEDefang 2.58 on 153.1.1.43 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200702/21 X-Sequence-Number: 3704 I've checked the script. It was a bug in the script. Now all the queries work fine. Sorry for disturbing. Mihail Quoting Michael Fuhr : > On Fri, Feb 09, 2007 at 07:53:46PM +0200, Mihail Mihailov wrote: >> > Only some PHP queries don't run? What's different about those that >> > run and those that don't? >> >> At first everything seemed to work fine. Connection works, queries run. >> So far I have found only one query, which worked in postgres 7.4 and >> doesn't seem to work now. It is a SELECT query with LIMIT and OFFSET >> clauses. >> The first query with OFFSET 0 worked, but the second with OFFSET N >> returned an empty recordset. >> I suspected that it has to do with php because the same query works >> fine in psql environment. > > Have you turned on statement logging in the database to verify that > PHP is sending the query you think it is? Have you looked for > errors in the database logs? What does the PHP code that fetches > the results look like? > >> Actually, these queries do not fail they just don't return any data. >> Do you think it's more likely a bug in the script? > > Impossible to say without more information. A self-contained test > case might be useful. > >> > If you ever upgrade PHP to use 8.x libraries instead of 7.4 libraries, >> > beware that some prepared queries that used to work might start >> > failing. >> >> So, you think it is not a good idea to make php use the 8.x libpq? > > I didn't mean to suggest not using libpq 8.x; I was suggesting that > you review your queries to make sure you're not depending on implicit > type casts that PDO's emulated prepared statements might be making > that will no longer be made with the "real" prepared statements > that PDO uses when linked against libpq 8.x. > > -- > Michael Fuhr > --=20 Mihail Mihailov, lehtori K=C3=A4=C3=A4nn=C3=B6stiede (ven=C3=A4j=C3=A4) Kieli- ja k=C3=A4=C3=A4nn=C3=B6stieteiden laitos 33014 Tampereen yliopisto puh. (03) 3551 6123 s=C3=A4hk=C3=B6posti: mihail.mihailov@uta.fi