配置PHP与IBM-DB2驱动程序连接Apache derby数据库的问题 [英] problem with configure PHP with IBM-DB2 driver for connecting Apache derby database

查看:127
本文介绍了配置PHP与IBM-DB2驱动程序连接Apache derby数据库的问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,


我正在尝试使用IBM-DB2配置php,当我运行configure命令时,我得到了以下内容


./configure --with-pdo-odbc = ibm-db2,/ opt / IBM / db2 / V8.1 /


输出:


检查PDO的ODBC v3支持...是

检查PDO包括...检查PDO包括... /home/knellim/php-5.3.1/ext

检查选定的PDO ODBC风格... ibm-db2

libs /opt/IBM/db2/V8.1//lib,

header /opt/IBM/db2/V8.1//包含

检查/opt/IBM/db2/V8.1中的odbc.h //包括...没有

检查/opt/IBM/db2/V8.1中的odbcsdk.h //包括...没有

在/opt/IBM/db2/V8.1中检查iodbc.h // include ... no

在/opt/IBM/db2/V8.1中检查sqlunix.h //包括...没有

检查sqltypes。 h in /opt/IBM/db2/V8.1//包含...没有

检查/opt/IBM/db2/V8.1中的sqlucode.h //包括...

检查在/opt/IBM/db2/V8.1中输入sql.h //包含...是

检查/opt/IBM/db2/V8.1中的isql.h//include ...没有

检查sqlext.h在/opt/IBM/db2/V8.1//include ...是

检查/q中的isqlext.h opt / IBM / db2 / V8.1 // include ... no

检查/opt/IBM/db2/V8.1中的udbcext.h //包括...没有
检查/opt/IBM/db2/V8.1中的sqlcli1.h是否包含...是

检查/ opt / IBM / db2 / V8中的LibraryManager.h .1 // include ... no

检查/opt/IBM/db2/V8.1中的cli0core.h //包括...否

检查cli0ext.h在/opt/IBM/db2/V8.1中包含...否

检查/opt/IBM/db2/V8.1中的cli0cli.h是否包括.. 。没有

在/opt/IBM/db2/V8.1中检查cli0defs.h //包括...没有


所以基本上,我有安装了DB2运行时客户端,但是没有成功连接到Apache Derby数据库所需的头文件。


当我运行connect php脚本时,我收到错误消息

SQLSTATE [IM002] SQLConnect:0 [unixODBC] [驱动程序管理器]未找到数据源名称,并且未指定默认驱动程序


请,任何有的人使用IBM-DB2配置PHP请帮助我..它的紧急!!

Hi All,

I am trying to configure php with IBM-DB2 and I get the followinng when i run the configure command

./configure --with-pdo-odbc=ibm-db2,/opt/IBM/db2/V8.1/

THE OUTPUT:

checking for ODBC v3 support for PDO... yes
checking for PDO includes... checking for PDO includes... /home/knellim/php-5.3.1/ext
checking for selected PDO ODBC flavour... ibm-db2
libs /opt/IBM/db2/V8.1//lib,
headers /opt/IBM/db2/V8.1//include
checking for odbc.h in /opt/IBM/db2/V8.1//include... no
checking for odbcsdk.h in /opt/IBM/db2/V8.1//include... no
checking for iodbc.h in /opt/IBM/db2/V8.1//include... no
checking for sqlunix.h in /opt/IBM/db2/V8.1//include... no
checking for sqltypes.h in /opt/IBM/db2/V8.1//include... no
checking for sqlucode.h in /opt/IBM/db2/V8.1//include... no
checking for sql.h in /opt/IBM/db2/V8.1//include... yes
checking for isql.h in /opt/IBM/db2/V8.1//include... no
checking for sqlext.h in /opt/IBM/db2/V8.1//include... yes
checking for isqlext.h in /opt/IBM/db2/V8.1//include... no
checking for udbcext.h in /opt/IBM/db2/V8.1//include... no
checking for sqlcli1.h in /opt/IBM/db2/V8.1//include... yes
checking for LibraryManager.h in /opt/IBM/db2/V8.1//include... no
checking for cli0core.h in /opt/IBM/db2/V8.1//include... no
checking for cli0ext.h in /opt/IBM/db2/V8.1//include... no
checking for cli0cli.h in /opt/IBM/db2/V8.1//include... no
checking for cli0defs.h in /opt/IBM/db2/V8.1//include... no

So basically, I have installed the DB2 runtime client but there are no header files in that needed for the succesful connection to Apache Derby database.

When i run my connect php script i get error message
SQLSTATE[IM002] SQLConnect: 0 [unixODBC][Driver Manager]Data source name not found, and no default driver specified

PLEASE, anyome who has configured PHP with IBM-DB2 pls help me.. Its urgent!!

推荐答案

你如何连接数据库?


请参阅php上的页面。 net。
Please see this page on php.net.


我使用CATALOG TCPIP命令连接到数据库。我的数据库位于同一台机器上。

我在Opt / Apache / derby / bin中启动了Derby Network serveri,给出了

#。/ startNetworkserver&


创建的数据库名为vcl

然后,我启动DB2 CLI并提供以下命令

db2 => ;目录tcpip节点vclnode远程localhost服务器1527

db2 =>目录db vCL节点vclnode认证服务器

db2 =>使用vclPassw

这连接了我的DB2客户端和derby数据库,因为我可以通过给出select命令看到表格,


你可以帮我连接PHP和DB2。谢谢....提前
I connect to the DB using the CATALOG TCPIP command. My database is located on the same machine.
I start the Derby Network serveri in Opt/Apache/derby/bin by giving
# ./startNetworkserver&

The database created is named as vcl
Then, I start the DB2 CLI and give the below commands
db2=>catalog tcpip node vclnode remote localhost server 1527
db2=>catalog db VCL at node vclnode authetication server
db2=>connect to VCL user vcluser using vclPassw

This connectd my DB2 client and derby database as I can see tables by giving select command,

Can u help me in connecting PHP with DB2. Thanks....in advance


这篇关于配置PHP与IBM-DB2驱动程序连接Apache derby数据库的问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆