Is it possible to make a connection to Postgresql via ODBC in Delphi 7?

Asked

Viewed 1,256 times

1

I’m having difficulties to make the connection to the database Postgresql in the Delphi 7, I got it from Zeos Lib, but I need it to be via dbExpress the connection, then I saw that in the most current versions of Delphi it is possible to make the connection via ODBC, however the Delphi 7 does not provide this option, will have some component that I need to add to be able to perform such connection via ODBC in the Delphi 7?

1 answer

2


A. Santos to use ODBC connection it is necessary to use the ADO components, with it it is possible to perform the connection through the lib odbc of Postgresql.

To get started download the lib odbc from postgresql https://odbc.postgresql.org/

Then add an Adoconnection component to your project and configure the Connectionstring property by selecting the Provider Postgresql OLE Provider and filling in the other available options for connection to the database.

Once this is done, turn on Adoconnection and place an Adodataset, specify the SQL command and you can use it alone or in conjunction with the Provider + clientdataset dataset.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.