各位大侠,这绝不是老调重弹。我已经在网上搜了N次,也没有找到我需要的答案。无奈只好求教各位大侠:
我现在用的是VB6.0,需要与MySQL数据库建立连接。我使用ADO进行连接,但注意不想使用ODBC连接(在网上查了,基本全部都是ODBC连接方式),而想使用OLEDB方式。
在网上也查到了连接使用的语句(Provider=MySQLProv;Data Source=mydb;User Id=myUsername;Password=myPassword;)以上语句引自网站 http://www.connectionstrings.com。
代入我自己的相应的参数之后测试错误:实时错误‘3706’:未找到提供程序。该程序可能未正确安装。(注:我安装的是MySQL的5.1.48-win32版,操作系统winXP-SP2,安装之后MySQL服务已经启动。)
在网上费了九牛二虎之力也没有搜到原因。
请哪位大侠能够指点我,最好说明具体的原因,如有详细代码就更好了;或者告诉我MySQL支持不支持OLEDB连接和理由。我实在是没辙了。因为MySQL对我来说,我还是一个菜鸟级别。
越快越好,在线等!谢谢!!!
我现在用的是VB6.0,需要与MySQL数据库建立连接。我使用ADO进行连接,但注意不想使用ODBC连接(在网上查了,基本全部都是ODBC连接方式),而想使用OLEDB方式。
在网上也查到了连接使用的语句(Provider=MySQLProv;Data Source=mydb;User Id=myUsername;Password=myPassword;)以上语句引自网站 http://www.connectionstrings.com。
代入我自己的相应的参数之后测试错误:实时错误‘3706’:未找到提供程序。该程序可能未正确安装。(注:我安装的是MySQL的5.1.48-win32版,操作系统winXP-SP2,安装之后MySQL服务已经启动。)
在网上费了九牛二虎之力也没有搜到原因。
请哪位大侠能够指点我,最好说明具体的原因,如有详细代码就更好了;或者告诉我MySQL支持不支持OLEDB连接和理由。我实在是没辙了。因为MySQL对我来说,我还是一个菜鸟级别。
越快越好,在线等!谢谢!!!
Dim conn As New ADODB.Connection
Dim rs As New ADODB.Recordset
conn.Open "Driver=MySQL ODBC 3.51 Driver; " & _
"Server=LocalHost; " & _
"Port=3306; " & _
"Database=test; " & _
"Uid=root;" & _
"Pwd=root"
这个是用ADO的连接串,2003年已经有了,但还是要安装ODBC的啊
20.1. MySQL Connector/ODBC
20.1.1. Connector/ODBC Versions
20.1.2. Connector/ODBC Introduction
20.1.3. Connector/ODBC Installation
20.1.4. Connector/ODBC Configuration
20.1.5. Connector/ODBC Examples
20.1.6. Connector/ODBC Reference
20.1.7. Connector/ODBC Notes and Tips
20.1.8. Connector/ODBC Support
20.2. MySQL Connector/NET
20.2.1. Connector/NET Versions
20.2.2. Connector/NET Installation
20.2.3. Connector/NET Visual Studio Integration
20.2.4. Connector/NET Tutorials
20.2.5. Connector/NET Programming
20.2.6. Connector/NET Connection String Options Reference
20.2.7. Connector/NET API Reference
20.2.8. Connector/NET Support
20.2.9. Connector/NET FAQ
20.3. MySQL Connector/J
20.3.1. Connector/J Versions
20.3.2. Connector/J Installation
20.3.3. Connector/J Examples
20.3.4. Connector/J (JDBC) Reference
20.3.5. Connector/J Notes and Tips
20.3.6. Connector/J Support
20.4. MySQL Connector/MXJ
20.4.1. Connector/MXJ Overview
20.4.2. Connector/MXJ Versions
20.4.3. Connector/MXJ Installation
20.4.4. Connector/MXJ Configuration
20.4.5. Connector/MXJ Reference
20.4.6. Connector/MXJ Notes and Tips
20.4.7. Connector/MXJ Support
20.5. MySQL Connector/C++
20.5.1. MySQL Connector/C++ Binary Installation
20.5.2. MySQL Connector/C++ Source Installation
20.5.3. MySQL Connector/C++ Building Windows applications with Microsoft Visual Studio
20.5.4. MySQL Connector/C++ Building Linux applications with NetBeans
20.5.5. MySQL Connector/C++ Getting Started: Usage Examples
20.5.6. MySQL Connector/C++ Tutorials
20.5.7. MySQL Connector/C++ Debug Tracing
20.5.8. MySQL Connector/C++ Usage Notes
20.5.9. MySQL Connector/C++ Known Bugs and Issues
20.5.10. MySQL Connector/C++ Feature requests
20.5.11. MySQL Connector/C++ Support
20.5.12. MySQL Connector/C++ FAQ
20.6. MySQL Connector/C
20.6.1. Building MySQL Connector/C from the Source Code
20.6.2. Testing MySQL Connector/C
20.6.3. MySQL Connector/C FAQ
20.7. MySQL Connector/OpenOffice.org
20.7.1. Installation
20.7.2. Getting Started: Connecting to MySQL
20.7.3. Getting Started: Usage Examples
20.7.4. References
20.7.5. Known Bugs
20.7.6. Contact
20.8. libmysqld, the Embedded MySQL Server Library
20.8.1. Compiling Programs with libmysqld
20.8.2. Restrictions When Using the Embedded MySQL Server
20.8.3. Options with the Embedded Server
20.8.4. Embedded Server Examples
20.8.5. Licensing the Embedded Server
20.9. MySQL C API
20.9.1. C API Data Types
20.9.2. C API Function Overview
20.9.3. C API Function Descriptions
20.9.4. C API Prepared Statements
20.9.5. C API Prepared Statement Data types
20.9.6. C API Prepared Statement Function Overview
20.9.7. C API Prepared Statement Function Descriptions
20.9.8. C API Threaded Function Descriptions
20.9.9. C API Embedded Server Function Descriptions
20.9.10. Common Questions and Problems When Using the C API
20.9.11. Controlling Automatic Reconnection Behavior
20.9.12. C API Support for Multiple Statement Execution
20.9.13. C API Prepared Statement Problems
20.9.14. C API Prepared Statement Handling of Date and Time Values
20.9.15. C API Support for Prepared CALL Statements
20.9.16. Building Client Programs
20.10. MySQL PHP API
20.10.1. MySQL
20.10.2. MySQL Improved Extension (Mysqli)
20.10.3. MySQL Native Driver (Mysqlnd)
20.10.4. MySQL Functions (PDO_MYSQL)
20.10.5. Connector/PHP
20.10.6. Common Problems with MySQL and PHP
20.10.7. Enabling Both mysql and mysqli in PHP
20.11. MySQL Perl API
20.12. MySQL C++ API
20.13. MySQL Python API
20.14. MySQL Ruby APIs
20.14.1. The MySQL/Ruby API
20.14.2. The Ruby/MySQL API
20.15. MySQL Tcl API
20.16. MySQL Eiffel Wrapper
你去找第三方吧.
搜索一下mysql oledb.
另一个1.72MB,调用之后,仍然提示:实时错误‘3706’:未找到提供程序。该程序可能未正确安装。也就是和不安装驱动一样的提示。
而且这个安装之后还要在网站进行激活,我也激活了,不知道错在哪里。
请大侠指教。
微软自已的东西,当然ado比odbc好,但是mysql不是微软的呀。
你为何非要用 ado 呢?odbc不好吗?请说说你非要用 ado 的理由好吗?
http://blog.csdn.net/CHRL/archive/2009/12/24/5070389.aspx