From:
Operating system: ubuntu 10.04
PHP version: 5.3.2
Package: CGI related
Bug Type: Bug
Bug description:php-cgi 5.3.2-1 pg_connect() error
Description:
------------
php-cgi 5.3.2-1 pg_connect() error
PHP Version 5.3.2-1
PostgreSQL(libpq) Version 8.4.3
Multibyte character support enabled
SSL support enabled
Active Persistent Links 0
Active Links 0
Directive Local Value Master Value
pgsql.allow_persistent On On
pgsql.auto_reset_persistent Off Off
pgsql.ignore_notice Off Off
pgsql.log_notice Off Off
pgsql.max_links Unlimited Unlimited
pgsql.max_persistent Unlimited Unlimited
PHP:
<?php
$conn=pg_connect('host=127.0.0.1 port=5432 dbname=fc user=fc
password=li');
var_dump($conn);
echo 'ok';
$rs=pg_exec('select * from yonghu');
$row=pg_fetch_array($rs);
var_dump($row);
liuge...@www:/etc/php5/cgi$
output:
bool(false) okNULL
Test script:
---------------
php-cgi 5.3.2-1 pg_connect() error
PHP Version 5.3.2-1
PostgreSQL(libpq) Version 8.4.3
Multibyte character support enabled
SSL support enabled
Active Persistent Links 0
Active Links 0
Directive Local Value Master Value
pgsql.allow_persistent On On
pgsql.auto_reset_persistent Off Off
pgsql.ignore_notice Off Off
pgsql.log_notice Off Off
pgsql.max_links Unlimited Unlimited
pgsql.max_persistent Unlimited Unlimited
PHP:
<?php
$conn=pg_connect('host=127.0.0.1 port=5432 dbname=fc user=fc
password=li');
var_dump($conn);
echo 'ok';
$rs=pg_exec('select * from yonghu');
$row=pg_fetch_array($rs);
var_dump($row);
liuge...@www:/etc/php5/cgi$
output:
bool(false) okNULL
--
Edit bug report at http://bugs.php.net/bug.php?id=51856&edit=1
--
Try a snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=51856&r=trysnapshot52
Try a snapshot (PHP 5.3):
http://bugs.php.net/fix.php?id=51856&r=trysnapshot53
Try a snapshot (PHP 6.0):
http://bugs.php.net/fix.php?id=51856&r=trysnapshot60
Fixed in SVN:
http://bugs.php.net/fix.php?id=51856&r=fixed
Fixed in SVN and need be documented:
http://bugs.php.net/fix.php?id=51856&r=needdocs
Fixed in release:
http://bugs.php.net/fix.php?id=51856&r=alreadyfixed
Need backtrace:
http://bugs.php.net/fix.php?id=51856&r=needtrace
Need Reproduce Script:
http://bugs.php.net/fix.php?id=51856&r=needscript
Try newer version:
http://bugs.php.net/fix.php?id=51856&r=oldversion
Not developer issue:
http://bugs.php.net/fix.php?id=51856&r=support
Expected behavior:
http://bugs.php.net/fix.php?id=51856&r=notwrong
Not enough info:
http://bugs.php.net/fix.php?id=51856&r=notenoughinfo
Submitted twice:
http://bugs.php.net/fix.php?id=51856&r=submittedtwice
register_globals:
http://bugs.php.net/fix.php?id=51856&r=globals
PHP 4 support discontinued: http://bugs.php.net/fix.php?id=51856&r=php4
Daylight Savings: http://bugs.php.net/fix.php?id=51856&r=dst
IIS Stability:
http://bugs.php.net/fix.php?id=51856&r=isapi
Install GNU Sed:
http://bugs.php.net/fix.php?id=51856&r=gnused
Floating point limitations:
http://bugs.php.net/fix.php?id=51856&r=float
No Zend Extensions:
http://bugs.php.net/fix.php?id=51856&r=nozend
MySQL Configuration Error:
http://bugs.php.net/fix.php?id=51856&r=mysqlcfg