Re: Call to undefined function: pg_connect()
| From: | Tyler Lane | Date: | Tue, 02 Sep 2003 16:44:24 +0000 |
| Subject: | Re: Call to undefined function: pg_connect() | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-30280@lists.php.net to get a copy of this message | ||
run phpinfo() and verify that postgresql support is indeed there.
Is the version of php-pgsql you installed been compiled for 7.3.4?
If it was compiled for postgresql 7.2 then it won't work with 7.3.x
libraries.
HTH
On Tue, 2003-09-02 at 07:31, Jennifer Liu wrote:
> Hi,
>
>
> I'm writing my first script in php to connect to a postgresql database
> on a Linux box with apache web server.
> - httpd-2.0.40-21.3.i386.rpm
> - php-4.2.2-17.2.i386.rpm and php-pgsql-4.2.2-17.2.i386.rpm
> - postgresql-7.3.4.tar.gz
>
> When I try to load the page, I get the error:
> Fatal error: Call to undefined function: pg_connect() in /var/www/html/tutorials/guestbook.php
> on line 136
>
> On line 136, I have:
> pg_connect("dbname=test");
>
> When I first got this error, I realized that I forgot to get the
> php-pgsql-4.2.2-17.2.i386.rpm too. After I got this rpm though, I
> still get the same error. Does anybody have any suggestions or ideas?
> Thanks so much!
>
> jenn.
--
Tyler Lane <tlane@lyrical.net>
Lyrical Communications
Attachment: [application/pgp-signature] This is a digitally signed message part signature.asc
Attachment: [application/pgp-signature] This is a digitally signed message part signature.asc