Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

C++ 2

Status
Not open for further replies.

pgomezsa

Programmer
Oct 24, 2002
7
0
0
US
Hi...

I am about develop an application on Borland C++ Builder 5.0, and the idea is to connect the application to a Postgresql 7.2 db that is running on linux...

do you think is going to work? i am kind of doubtful about the Windows-linux connectivity using C++....Will the libpq++ solve the problem? do I need any kind of dbc connection?

Thanks in advance.
 
As I understand it, if you use libpq, all you need is TCP/IP networking, and you can access a remote PostgreSQL database. You have to be careful to set up your pg_hba.conf file correctly to allow for remote connections, though, and you have to start the postgres daemon with the -i option.

ODBC also works quite well, though. Just go to and download psqlODBC to install on any Windows system that will be accessing the database, and you have an ODBC connection to PostgreSQL. (I believe psqlODBC simply provides an ODBC "front end" to libpq which makes the actual connection to PostgreSQL) -------------------------------------------

Big Brother: "War is Peace" -- Big Business: "Trust is Suspicion"
(
 
so...it doesn't matter if my C++ is under Windows and my db is under linux?...I am not going to have any configuration or compatibilities issues?

Thanks for your answer...
 
No it doesn't. As long as you have the client libraries for your Windows box, it doesn't care what OS the PostgreSQL server is running. //Daniel
 
me again...

so I will have to download the libpq++ library files for Windows, put those on my Windows box and include the library on my program to connect to the Postgresql db?

Where can I get the libpq++ library?

have you used it?...do you know about performance issues? or bugs?

Thanks!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top