将MySQL数据库添加到ODBC的程序 [英] Programme To Add MySQL Database To The ODBC

查看:88
本文介绍了将MySQL数据库添加到ODBC的程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

请我需要一个代码,以编程方式将MySQL数据库添加到ODBC中,该程序应首先检查数据库是否已添加到ODBC中,否则应添加它.我正在设计一个应用程序,该应用程序将从连接到ODBC的MySQL数据库中读取数据,并且希望以编程方式进行连接,而不是用户手动添加它.非常感谢您提供的帮助.

Please I need a code to add a MySQL database to the ODBC programmatically, The programme should first check to see if the database has already been added to the ODBC else it should add it. I am designing an application that will read from the a MySQL database connected to ODBC and I would have wished to do the connection programmatically instead of the user manually adding it. I will be very grateful for a help extended to me regarding this.

推荐答案

创建的DSN条目将存储在系统注册表中,这意味着如果您要添加一个,您需要使用注册表设置.我发现很少有链接可以帮助您实现这一目标.请看看,如果他们不起作用,请不要骂我;):D

http://forums.ni.com/t5/LabVIEW/Creating- a-DSN-programmatically/td-p/301189 [ ^ ]

http://support.microsoft.com/kb/q184608/ [ http://support.microsoft.com/kb/q110507/ [
DSN entries created would be stored in System Registry, which means if you wish to add one, you need to play with the registry setting. I have found few links that might help you achieve that. Please have a look and dont curse me if they don''t work ;) :D

http://forums.ni.com/t5/LabVIEW/Creating-a-DSN-programmatically/td-p/301189[^]

http://support.microsoft.com/kb/q184608/[^]

http://support.microsoft.com/kb/q110507/[^]


这篇关于将MySQL数据库添加到ODBC的程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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