PHP 4.0 Bug #8231 Updated: db2 driver for dba not working
| From: | cech at debian dot org | Date: | Thu, 21 Dec 2000 23:27:26 +0000 |
| Subject: | PHP 4.0 Bug #8231 Updated: db2 driver for dba not working | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-42091@lists.php.net to get a copy of this message | ||
ID: 8231
User Update by: cech@debian.org
Old-Status: Open
Status: Closed
Bug Type: DBM/DBA related
Description: db2 driver for dba not working
Hi,
I've found out the problem. Apache and php4 were using different
DB2 libraries - one from glibc and the other Sleepycat one. After recompiling apache
it's all OK.
Sorry
Petr Cech
Previous Comments:
---------------------------------------------------------------------------
[2000-12-21 18:13:37] cech@debian.org
Hi,
I didn't want to imply, that ndbm has some impact on db2. Only note,
that other DBA drivers work.
No. there is nothing in the error logs. 4.0.3pl1 worked OK. Maybe it's just libraries.
I'll try to investigate more, but probably
after holidays.
Petr Cech
---------------------------------------------------------------------------
[2000-12-20 19:10:19] sniper@php.net
I compiled ndbm support into my test bed and this still works just fine for
me. What is the version of db2 you're using?
Are there any errors in log files?
--Jani
---------------------------------------------------------------------------
[2000-12-20 10:21:16] cech@debian.org
phpinfo() says it knows db2 and ndbm backends. The ndbm
works OK, but db2 doesn't.
Warning: driver initialization failed in /home/cech/WWW/php4/test-db2.php on line 2
dba_open failed
It creates an empty .db file and that's all. Normal C programs
work with db2 as expected.
Petr Cech
---------------------------------------------------------------------------
[2000-12-19 20:54:44] sniper@php.net
Does it get compiled in? ie. What does phpinfo() say about it?
Does the script print out any error messages?
--Jani
---------------------------------------------------------------------------
[2000-12-18 04:21:19] cech@debian.org
Hi,
it's still happening. I've tried and packaged RC6 and it doesn't seem
to work with glibc 2.2 and LFS perhaps.
<?
$dbh = dba_open("/tmp/test.db2","c","db2");
if(!$dbh) {
echo "dba_open failedn";
exit;
}
dba_replace ("key", "This is an example!", $dbh);
if (dba_exists ("key", $dbh)) {
echo dba_fetch ("key", $dbh);
dba_delete ("key", $dbh);
}
dba_close ($dbh);
?>
---------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view the rest of the comments,
please view the bug report online.
Full Bug description available at: http://bugs.php.net/?id=8231