Active3 years, 8 months ago
I am setting up an database application to be database agnostic, and when testing with postgresql I get the standard dsn error:
PsqlODBC - PostgreSQL ODBC driver. PsqlODBC is the official PostgreSQL ODBC Driver. It is released under the Library General Public Licence, or LGPL. Downloads are available in source and binary formats at the PostgreSQL downloads site.
[IM002] [Microsoft][ODBC Driver Manager] Data source name not found
- The installation said that it was sucessful, but I cannot see the odbc driver in the ODBC data sources administrator. Is there something that I have to do on Windows 64 bit to use the driver? Just found this in the microsoft odbc newsgroup. Perhaps it helps.
- Jul 31, 2019 Microsoft ODBC Driver 17 for SQL Server is a single dynamic-link library (DLL) containing run-time support for applications using native-code APIs to connect to Microsoft SQL Server 2008, SQL Server 2008 R2, SQL Server 2012, SQL Server 2014, SQL Server 2016, SQL Server 2017, Analytics Platform System, Azure SQL Database and Azure SQL Data Warehouse.
- 3) When trying to call a function from the Postgres DB, getting below error, 'OLE DB or ODBC error: MicrosoftODBC Driver Manager Data source name not found and no default driver specified; IM002. A connection could not be made to the data source with the DataSourceID' Please suggest.
- Feb 28, 2018 Connection libraries for Azure Database for PostgreSQL - Single Server. 5/6/2019; 2 minutes to read; In this article. This article lists libraries and drivers that developers can use to develop applications to connect to and query Azure Database for PostgreSQL.
I usually use SQL server and MySQL so I'm new to postgres, I tried the standard recommended Connection string:
I also tried the name of the odbc driver that I installed after installing postrgesql:
Setting up a DSN in odbc manager also works perfectly using the unicode driver, so I cant understand why i cant connect in my application, is there an error in the driver name that i am using in the connection string?
Soner Gönül83.6k2727 gold badges161161 silver badges294294 bronze badges
sjwbondsjwbond
2 Answers
Your error message looks very strange. It tells about DSN not found. Are you sure you use connect string with
Driver=..
?You can use ODBC connect string in several forms. At first you have created DSN, so you can use it:
Then you can use other form of connect string:
Both work on my old 32 bit Windows environment. I test them with simple Python script (I use ActiveState Python in which there is simple
Michał NiklasMichał Niklasodbc
module):42.5k1414 gold badges5959 silver badges9494 bronze badges
When you created the DSN, did you create it with the correct odbcad tool? With the 64bit version found in
ergC:WindowsSystem32
if your application is 64bit and with the 32bit version found in C:WindowsSysWOW64
if your application is 32bit?![Driver Driver](https://blog.pythian.com/wp-content/uploads/Capture3-1.png)
1,31111 gold badge77 silver badges1616 bronze badges
Not the answer you're looking for? Browse other questions tagged c#databaseodbcpostgresql-9.5 or ask your own question.
Active5 months ago
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 :
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
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.
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.
pnuts51k77 gold badges6565 silver badges105105 bronze badges
user2437443user243744362633 gold badges99 silver badges2222 bronze badges
7 Answers
- In reference to the error: [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified.That error means that the Data Source Name (DSN) you are specifying in your connection configuration is not being found in the windows registry.
- 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.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).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
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. - 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.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.
- 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.
7,26822 gold badges1515 silver badges2929 bronze badges
PRGSTonyPRGSTony
Got this error because I had the Data Source Name in User DSN instead of System DSN Download jw library free for laptop.
Jan Doggen5,4231313 gold badges4848 silver badges9494 bronze badges
Postgres 32 Bit Odbc Driver
NickNickPostgres Odbc Windows
1,88722 gold badges2222 silver badges3737 bronze badges
The Problem might be from the driver name for example instead of
DRIVER={MySQL ODBC 5.3 Driver}
try DRIVER={MySQL ODBC 5.3 Unicode Driver}
you can see the name of the driver from administration toolMeysamMeysam
I got this with data driven tests using:
The problem is the above driver only is 32 bit. I had switched visual studio testsettings file to 64 bit to test a 64-bit-only application.
Switching back to 32 bit in the testsettings file fixed the issue.
N-ateN-ate
I tried the above but found my issue was I used a | in the name of the DSN (I have multipled ODBC connectors - one for each DB - to make sure I don't comingle data)
I replaced the | (pipe) with a _ and all now works fine.
I was trying to call SQL Server from Alteryx.
calepcalep
Following the instructions here http://help.loftware.com/pages/viewpage.action?pageId=27099554 I had to install the Microsoft Access Database Engine 2010 Redistributable before I had the Excel driver installed to use the DSN-less connection I wanted to use from perl.
Matthew LockMatthew Lock8,61977 gold badges6868 silver badges113113 bronze badges
if you are using IIS, maybe you should try
'application pools' --> 'DefaultAppPool' --> 'application pools default value'--> '32-Bit-application-activ' --> set false
'application pools' --> 'DefaultAppPool' --> 'application pools default value'--> '32-Bit-application-activ' --> set false
leslieleslie