PHP和Access [英] PHP and Access

查看:71
本文介绍了PHP和Access的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

需要帮助来调试这个问题。


我有一个访问数据库,我用来演示Java - ODBC

连接,它工作正常。


我试图访问相同的DSN(系统DSN)thro''PHP和

以下错误显示。


警告:odbc_connect()[function.odbc-connect]:SQL错误:

[Microsoft] [ODBC驱动程序管理器]未找到数据源名称且没有

指定了默认驱动程序,SQLConnect中的SQL状态IM002位于第8行的
D:\Ajith \Teaching\PHP \Examples \\\\\\\\\\\\\\\\\\\ b连接失败:


数据库在那里,定义了DSN,可以通过Java访问DSN,但不能使用PHP访问


任何知道问题是什么以及

问题解决方案是什么的人。


我使用的是php5.0.1


谢谢

解决方案

只是为了澄清这种情况(参考我的原始邮件)。


我设置了ODBC(自动设置为Access)。 ODBC驱动程序

适用于Java(通过JDBC-ODBC桥)。在PHP程序中使用相同的DSN

并且它不起作用。


非常感谢任何帮助/指针等。在

网上搜索2天并没有解决问题。如果在

上搜索错误信息,可以找到许多具有相同

问题的操作站点。


谢谢


Ajith


aj********@yahoo.com (AP Madura)在留言中写道:< 47 ********************* *****@posting.google。 com> ...

警告:odbc_connect()[function.odbc-connect]:SQL错误:
[Microsoft] [ODBC驱动程序管理器]未找到数据源名称且没有
默认驱动程序指定,SQLConnect中的SQL状态IM002在第8行D:\ Ajith \Teaching\PHP \ Example> \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ blockquote>

< snip>


手册和用户注释是你的好友< http://in2.php.net/odbc_connect>


-

|只是另一个PHP圣人|

电子邮件:rrjanbiah-at-Y!com


Need help in debugging this problem.

I have an access database which I used to demonstrate Java - ODBC
connectivity and it works fine.

I tried to access the same DSN (system DSN) thro'' PHP and the
following error is displayed.

Warning: odbc_connect() [function.odbc-connect]: SQL error:
[Microsoft][ODBC Driver Manager] Data source name not found and no
default driver specified, SQL state IM002 in SQLConnect in
D:\Ajith\Teaching\PHP\Examples\php\dbmstest.php on line 8
Connection Failed:

Database is there, DSN is defined, can access the DSN via Java but not
with PHP.

Anybody who knows what the problem is and what the solution to the
problem is.

I am using php5.0.1

Thanks

解决方案

Just to clarify the situation (with reference to my original mail).

I have ODBC set up (automatically set up for Access). ODBC driver
works fine with Java (via JDBC-ODBC bridge). The same DSN is used in
the PHP program and it doesnt work.

Any help/pointers etc is much appreciated. 2 days of searching on the
web did not yield a solution to the problem. If one does a search on
the error message, one can find many operative sites having the same
problem.

Thanks

Ajith


aj********@yahoo.com (A.P. Madura) wrote in message news:<47**************************@posting.google. com>...

Warning: odbc_connect() [function.odbc-connect]: SQL error:
[Microsoft][ODBC Driver Manager] Data source name not found and no
default driver specified, SQL state IM002 in SQLConnect in
D:\Ajith\Teaching\PHP\Examples\php\dbmstest.php on line 8
Connection Failed:


<snip>

Manual and the usernotes are your close friends <http://in2.php.net/odbc_connect>

--
| Just another PHP saint |
Email: rrjanbiah-at-Y!com


这篇关于PHP和Access的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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