From:             ahmet at cemre dot net
Operating system: Fedora Core release 3
PHP version:      5.1.2
PHP Bug Type:     *Database Functions
Bug description:  IBM DB2 problem

Description:
------------
Hello,

I'm compiling php 5.1.2 with db2 support but when i try to use db2_*
functions, it says "undefined function"

Configure command : 


 ./configure  --with-apxs=/usr/sbin/apxs --with-mysql --with-gd
--enable-gd --with-zlib --with-freetype --enable-gd-native-ttf --with-ttf
--with-jpeg-dir --with-unixODBC=/usr --with-mssql=/usr/local/freetds
--with-openssl --with-ibm-db2=/opt/IBM/db2/V8.1/




[EMAIL PROTECTED] httpdocs]# ldd /usr/local/bin/php  | grep IBM
        libdb2.so.1 => /opt/IBM/db2/V8.1//lib/libdb2.so.1 (0xb6fd1000)
        libdb2install.so.1 => /opt/IBM/db2/V8.1/lib/libdb2install.so.1
(0xb6fca000)
        libdb2g11n.so.1 => /opt/IBM/db2/V8.1/lib/libdb2g11n.so.1
(0xb6f45000)
        libdb2locale.so.1 => /opt/IBM/db2/V8.1/lib/libdb2locale.so.1
(0xb6f2d000)
        libdb2osse.so.1 => /opt/IBM/db2/V8.1/lib/libdb2osse.so.1
(0xb6d12000)
        libdb2genreg.so.1 => /opt/IBM/db2/V8.1/lib/libdb2genreg.so.1
(0xb6cca000)
        libdb2trcapi.so.1 => /opt/IBM/db2/V8.1/lib/libdb2trcapi.so.1
(0xb6cbd000)
        libdb2dascmn.so.1 => /opt/IBM/db2/V8.1/lib/libdb2dascmn.so.1
(0xb6c9c000)
        libcxa.so.3 => /opt/IBM/db2/V8.1/lib/libcxa.so.3 (0xb6c69000)
        libdb2osse_db2.so.1 => /opt/IBM/db2/V8.1/lib/libdb2osse_db2.so.1
(0xb6c54000)





[EMAIL PROTECTED] httpdocs]# /usr/local/bin/php -v
PHP 5.1.2 (cli) (built: Apr  8 2006 16:14:22)
Copyright (c) 1997-2006 The PHP Group
Zend Engine v2.1.0, Copyright (c) 1998-2006 Zend Technologies
[EMAIL PROTECTED] httpdocs]#




Reproduce code:
---------------
$database = 'ASYAWEB';
$user = 'db2inst1';
$password = 'xxx';

$conn = db2_connect($database, $user, $password);

if ($conn) {
   echo "Connection succeeded.";
   db2_close($conn);
}
else {
   echo "Connection failed.";
}


Expected result:
----------------
Connection succeeded


Actual result:
--------------
Fatal error: Call to undefined function db2_connect() in
/var/www/html/turkyayin.com/httpdocs/deneme.php on line 7

-- 
Edit bug report at http://bugs.php.net/?id=37018&edit=1
-- 
Try a CVS snapshot (PHP 4.4): 
http://bugs.php.net/fix.php?id=37018&r=trysnapshot44
Try a CVS snapshot (PHP 5.1): 
http://bugs.php.net/fix.php?id=37018&r=trysnapshot51
Try a CVS snapshot (PHP 6.0): 
http://bugs.php.net/fix.php?id=37018&r=trysnapshot60
Fixed in CVS:                 http://bugs.php.net/fix.php?id=37018&r=fixedcvs
Fixed in release:             
http://bugs.php.net/fix.php?id=37018&r=alreadyfixed
Need backtrace:               http://bugs.php.net/fix.php?id=37018&r=needtrace
Need Reproduce Script:        http://bugs.php.net/fix.php?id=37018&r=needscript
Try newer version:            http://bugs.php.net/fix.php?id=37018&r=oldversion
Not developer issue:          http://bugs.php.net/fix.php?id=37018&r=support
Expected behavior:            http://bugs.php.net/fix.php?id=37018&r=notwrong
Not enough info:              
http://bugs.php.net/fix.php?id=37018&r=notenoughinfo
Submitted twice:              
http://bugs.php.net/fix.php?id=37018&r=submittedtwice
register_globals:             http://bugs.php.net/fix.php?id=37018&r=globals
PHP 3 support discontinued:   http://bugs.php.net/fix.php?id=37018&r=php3
Daylight Savings:             http://bugs.php.net/fix.php?id=37018&r=dst
IIS Stability:                http://bugs.php.net/fix.php?id=37018&r=isapi
Install GNU Sed:              http://bugs.php.net/fix.php?id=37018&r=gnused
Floating point limitations:   http://bugs.php.net/fix.php?id=37018&r=float
No Zend Extensions:           http://bugs.php.net/fix.php?id=37018&r=nozend
MySQL Configuration Error:    http://bugs.php.net/fix.php?id=37018&r=mysqlcfg

Reply via email to