[Microsoft][ODBC 驱动程序管理器] 未找到数据源名称且未指定默认驱动程序 [英] [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified

查看:75
本文介绍了[Microsoft][ODBC 驱动程序管理器] 未找到数据源名称且未指定默认驱动程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我第一次尝试在使用 PostgreSQL 9 的 Windows XP Pro 上打开一个程序.我收到一条错误消息:

I am trying to open a program for the first time on Windows XP Pro that uses PostgreSQL 9. I'm getting an error message that says :

尝试登录或创建时遇到问题生产数据库.详细信息:[Microsoft][ODBC 驱动程序管理器] 数据未找到源名称且未指定默认驱动程序

A problem was encountered while trying to log into or create the production database. Details: [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified

在我的 ODBC 管理器中,我有一个用户 DSN 和系统 DSN 的列表.我尝试安装 postgres odbc 驱动程序以查看是否有帮助,但没有.

In my ODBC manager, I have a list of User DSN's and System DSN's. I tried installing a postgres odbc driver to see if that would help, but it didn't.

程序文件中有一个connect.dat 文件,有一行写着OLE DB Provider = MSDASQL".更改此条目会更改我收到的错误消息找不到提供程序,它可能未正确安装".

There is a connect.dat file in the program file with a line saying "OLE DB Provider = MSDASQL". Changing this entry alters the error message I get to "Provider cannot be found, it may not be properly installed".

我不知道要插入什么提供程序名称才能使其正常工作.我对此错误进行了广泛的研究,但无济于事.任何建议将不胜感激.

I don't know what provider name to insert to get this to work properly. I have done extensive research on this error to no avail. Any suggestions would be greatly appreciated.

推荐答案

  1. 参考错误:[Microsoft][ODBC Driver Manager] 未找到数据源名称且未指定默认驱动程序.

该错误意味着在 Windows 注册表中找不到您在连接配置中指定的数据源名称 (DSN).

That error means that the Data Source Name (DSN) you are specifying in your connection configuration is not being found in the windows registry.

  • 重要的是您的 ODBC 驱动程序的可执行文件和链接格式 (ELF) 与您的应用程序相同.换句话说,32 位应用程序需要 32 位驱动程序,64 位应用程序需要 64 位驱动程序.

  • It is important that your ODBC driver's executable and linking format (ELF) is the same as your application. In other words, you need a 32-bit driver for a 32-bit application or a 64-bit driver for a 64-bit application.

如果这些不匹配,则可以为 32 位驱动程序配置 DSN,当您尝试在 64 位应用程序中使用该 DSN 时,将找不到 DSN,因为注册表保存 DSN 信息在不同的地方取决于 ELF(32 位与 64 位).

If these do not match, it is possible to configure a DSN for a 32-bit driver and when you attempt to use that DSN in a 64-bit application, the DSN won't be found because the registry holds DSN information in different places depending on ELF (32-bit versus 64-bit).

确保您使用的是正确的 ODBC 管理器工具.在 32 位和 64 位 Windows 上,默认的 ODBC 管理器工具位于 c:WindowsSystem32odbcad32.exe.但是,在 64 位 Windows 计算机上,默认为 64 位版本.如果您需要在 64 位 Windows 系统上使用 32 位 ODBC 管理器工具,则需要运行在此处找到的工具:C:WindowsSysWOW64odbcad32.exe

Be sure you are using the correct ODBC Administrator tool. On 32-bit and 64-bit Windows, the default ODBC Administrator tool is in c:WindowsSystem32odbcad32.exe. However, on a 64-bit Windows machine, the default is the 64-bit version. If you need to use the 32-bit ODBC Administrator tool on a 64-bit Windows system, you will need to run the one found here: C:WindowsSysWOW64odbcad32.exe

当用户使用默认的 64 位 ODBC 管理器来配置 DSN 时,我看到这让人们感到不安;认为它适用于 32 位 DSN.然后,当 32 位应用程序尝试使用该 DSN 进行连接时,会出现未找到数据源...".

Where I see this tripping people up is when a user uses the default 64-bit ODBC Administrator to configure a DSN; thinking it is for a 32-bit DSN. Then when the 32-bit application attempts to connect using that DSN, "Data source not found..." occurs.

确保 DSN 的拼写与 ODBC 管理器中配置的 DSN 的拼写相匹配也很重要.一个字母错误就是 DSN 不匹配所需的全部.

It's also important to make sure the spelling of the DSN matches that of the configured DSN in the ODBC Administrator. One letter wrong is all it takes for a DSN to be mismatched.

这里有一篇文章可能会提供一些额外的细节

但是,它可能与您拥有的产品品牌不同;这是使用 ODBC 数据源名称时遇到的一般问题.

It may not be the same product brand that you have, however; it is a generic problem that is encountered when using ODBC data source names.

关于您问题的 OLE DB 提供程序部分,它似乎是应用程序无法找到指定提供程序的配置的类似问题类型.

In reference to the OLE DB Provider portion of your question, it appears to be a similar type of problem where the application is not able to locate the configuration for the specified provider.

这篇关于[Microsoft][ODBC 驱动程序管理器] 未找到数据源名称且未指定默认驱动程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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