how could I connect a Postgres database in c language using odbc?

Lists: pgsql-general
From: masculinu(at)hotmail(dot)com (Maus)
To: pgsql-general(at)postgresql(dot)org
Subject: how could I connect a Postgres database in c language using odbc?
Date: 2004-07-02 14:27:33
Message-ID: [email protected]
Views: Whole Thread | Raw Message | Download mbox | Resend email
Lists: pgsql-general

For connecting a DB (Oracle in this case) in JDBC I know the follow
java instructions:

Class.forName("oracle.jdbc.driver.OracleDriver");
String dbUrl = "jdbc:oracle:thin:@"+host+":"+port+":"+sid;
Connection m_connection = DriverManager.getConnection(dbUrl, user,
passwd);
Statement m_statement = m_connection.createStatement();

Now, I'd like to know the equivalent instructions in c language using
ODBC for connecting a Postgres database.

Please, could anyone help me and tell me which these instructions are?

Thanks and bye,
Maus