Solved

Connecting to PostgreSQL Linux Implementation from Visual Studio 2008

Posted on 2015-01-08
4
301 Views
Last Modified: 2015-01-13
What is the best method to connect from Visual Studio (and SSRS) to linux. I have tried DSN but keep seeing this message "The specified DSN contains an architecture mismatch between the Driver and Application".

Have also tried using connection string but no luck.

Please provide guides as to best method to use and complete syntax of connection string if required.

My Windows SQL and Visual Studio box is Windows 2008 Server.
0
Comment
Question by:nussedog
  • 2
4 Comments
 
LVL 83

Assisted Solution

by:Dave Baldwin
Dave Baldwin earned 150 total points
ID: 40539078
There are some connection string listed here that you might try:  http://www.connectionstrings.com/postgresql/
0
 
LVL 2

Assisted Solution

by:Mike Lloyd
Mike Lloyd earned 150 total points
ID: 40539262
It sounds like you have the wrong ODBC drivers. Try the PostgreSQL drivers, located here: http://www.postgresql.org/ftp/odbc/versions/msi/
0
 

Accepted Solution

by:
nussedog earned 0 total points
ID: 40539364
Thanks everyone.
I had already visited both the sites referenced above.

Turns out the actual issue was the configuration of the ODBC driver. There are two ODBC configuration tools provided by Microsoft. The default tool is the 32bit version and will install only 32 ODBC driver. I had to manually run the 64bit configuration tool  so that the correct 64bit ODBC driver would be installed.

The ODBC.ini file was correctly modified and lines 5 & 6 added after executing %windir%\syswow64\odbcad32.exe.
001 [ODBC 32 bit Data Sources]
002 PeopleNet=PostgreSQL ANSI(x64) (32 bit)
003 PeopleNet64=PostgreSQL Unicode (32 bit)
004 [PeopleNet]
005 Driver32=C:\Program Files\psqlODBC\0903\bin\psqlodbc30a.dll
006 [PeopleNet64]
007 Driver32=C:\Program Files (x86)\psqlODBC\0903\bin\psqlodbc35w.dll

I found a complete explanation of this 'oddity' at the link below:
http://www.easysoft.com/developer/interfaces/odbc/64-bit.html#odbc-windows
0
 

Author Closing Comment

by:nussedog
ID: 40546247
"A" for effort
0

Featured Post

U.S. Department of Agriculture and Acronis Access

With the new era of mobile computing, smartphones and tablets, wireless communications and cloud services, the USDA sought to take advantage of a mobilized workforce and the blurring lines between personal and corporate computing resources.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Let's review the features of new SQL Server 2012 (Denali CTP3). It listed as below: PERCENT_RANK(): PERCENT_RANK() function will returns the percentage value of rank of the values among its group. PERCENT_RANK() function value always in be…
Ever wondered why sometimes your SQL Server is slow or unresponsive with connections spiking up but by the time you go in, all is well? The following article will show you how to install and configure a SQL job that will send you email alerts includ…
Using examples as well as descriptions, and references to Books Online, show the different Recovery Models available in SQL Server and explain, as well as show how full, differential and transaction log backups are performed
Via a live example, show how to set up a backup for SQL Server using a Maintenance Plan and how to schedule the job into SQL Server Agent.

813 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now