38

I have the latest 64 bit version of PostgreSQL. I am running Win 7 64 bit. I had installed the ODBC driver (via the initial installer) when I installed PG, and upgraded it to the latest version from http://www.postgresql.org/ftp/odbc/versions/msi/.

However, when I go to the ODBC control panel and try to add a User DSN, PostgreSQL isn't listed as a server.

I was following the instructions given here, but I noted the links are dated.

IamIC
  • 16,207
  • 18
  • 81
  • 142

4 Answers4

41

As I see PostgreSQL installer doesn't include 64 bit version of ODBC driver, which is necessary in your case. Download psqlodbc_09_00_0310-x64.zip and install it instead. I checked that on Win 7 64 bit and PostgreSQL 9.0.4 64 bit and it looks ok:

enter image description here

Test connection:

enter image description here

Grzegorz Szpetkowski
  • 35,042
  • 4
  • 82
  • 127
  • Thanks. I installed the 0310-x64 fine, but I still don't get PG in the ODBC control panel. Is something else needed besides simply running the MSI? – IamIC Jul 23 '11 at 09:53
  • Installed it a second time, then is worked. Weird. Thanks much @Grzegorz! – IamIC Jul 23 '11 at 10:03
26

Installing psqlODBC on 64bit Windows

Though you can install 32 bit ODBC drivers on Win X64 as usual, you can't configure 32-bit DSNs via ordinary control panel or ODBC datasource administrator.

How to configure 32 bit ODBC drivers on Win x64

Configure ODBC DSN from %SystemRoot%\syswow64\odbcad32.exe

  1. Start > Run
  2. Enter: %SystemRoot%\syswow64\odbcad32.exe
  3. Hit return.
  4. Open up ODBC and select under the System DSN tab.
  5. Select PostgreSQL Unicode

You may have to play with it and try different scenarios, think outside-the-box, remember this is open source.

mivk
  • 9,883
  • 3
  • 55
  • 54
TSMurphy
  • 261
  • 3
  • 2
  • 3
    This worked for me! Note that after getting the 'connection successful' message on test I then got an architecture mismatch error. This was because the software modeler I was using was 32-bit and I had the 64-bit driver installed. I installed the 32-bit driver but had to follow the steps above to get it to show up in the configure tool since I had a 64-bit OS. Thanks again. – ralphinator80 Sep 22 '14 at 14:19
  • Solved my problem too!! =)))))) Thaks brow xD – JHenry Jan 31 '20 at 02:00
  • I am using 64-bit machine (and Visio 64-bit) but psqlODBC 64-bit is not showing at step (2). Maybe because it is odbcad**32**.exe. Either way, successfully works when I am using psqlODBC 32 bit installer. – fa wildchild Jul 15 '20 at 05:30
14

Please note that you must install the driver for the version of your software client(MS access) not the version of the OS. that's mean that if your MS Access is a 32-bits version,you must install a 32-bit odbc driver. regards

Patrick
  • 141
  • 1
  • 2
  • 12
    also note that C:\Windows\System32\odbcad32.exe manages your 64-bit ODBC drivers and DSNs, and C:\Windows\SysWOW64\odbcad32.exe manages your 32-bit ODBC drivers and DSNs – Noah Yetter Jan 08 '13 at 22:32
3

First you download ODBC driver psqlodbc_09_01_0200-x64.zip then you installed it.After that go to START->Program->Administrative tools then you select Data Source ODBC then you double click on the same after that you select PostgreSQL 30 then you select configure then you provide proper details such as db name user Id host name password of the same database in this way you will configured your DSN connection.After That you will check SSL should be allow .

Then you go on next tab system DSN then you select ADD tabthen select postgreSQL_ANSI_64X ODBC after you that you have created PostgreSQL ODBC connection.

Rushikesh
  • 31
  • 1