X-Original-To: pgsql-php@postgresql.org Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id C65E1476835 for ; Fri, 16 May 2003 15:00:30 -0400 (EDT) Received: from postgresql.org ([64.49.215.8]) by localhost (postgresql.org [64.49.215.8:10024]) (amavisd-new) with ESMTP id 27530-02 for ; Fri, 16 May 2003 15:00:28 -0400 (EDT) Received: from mail1.ihs.com (mail1.ihs.com [170.207.70.222]) by postgresql.org (Postfix) with ESMTP id 49CB0476C9C for ; Fri, 16 May 2003 15:00:26 -0400 (EDT) Received: from css120.ihs.com (css120.ihs.com [170.207.105.120]) by mail1.ihs.com (8.12.9/8.12.9) with ESMTP id h4GIxMar009984; Fri, 16 May 2003 12:59:22 -0600 (MDT) Date: Fri, 16 May 2003 12:48:56 -0600 (MDT) From: "scott.marlowe" To: Mark Cc: , "Marc G. Fournier" , Subject: Re: Inquiry From Form [pgsql] In-Reply-To: <20030515213729.8821D184E752@hub.org> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-MailScanner: Found to be clean X-MailScanner-SpamCheck: X-Virus-Scanned: by amavisd-new X-Archive-Number: 200305/18 X-Sequence-Number: 2023 On Thu, 15 May 2003, Mark wrote: > I have a Raq4i and I am trying to write PHP 4 to the PostgreSQL. But I > keep getting undefined function: pg_connect() . I have the extension > enabled and the PHP was compiled for postgreSQL. I do not understand > what is going on? If PHP says pg_connect is undefined, then the php the RAQ is running isn't compiled for postgresql connectivity. There are two common causes of this: 1: You compiled one build of PHP, the RAQ is running on another build. 2: You told PHP to build in postgresql connectivity, it couldn't find the right header file, failed, writing an error message to the screen during configuration, saying something along the lines of "could not find file xxxxx.h" skipping postgresql configuration. PHP will then happily build and run, without postgresql capabilities. Try this: write a web page with this in it: Look through the page to see if it mentions postgresql. At the top will be a list of all the switches it was configged with. If you have a --with-pgsql there, but no pgsql section in phpinfo, then the configure script couldn't find the right headers. Make sure you're running a fairly late model version of both PHP and postgresql, as there was a bit of an issue about a year ago when postgresql changed the name of one of it's connection headers.