Re: [GENERAL] error linking with PostgreSQL

2009-11-22 Thread Tom Lane
Daniel writes: > PGconn pg_conn; You probably want that to be "PGconn *pg_conn;" > db_util.h:11: error: field 'pg_conn' has incomplete type libpq doesn't expose the struct type PGconn, only pointers to it. regards, tom lane -- Sent via pgsql-general mailing list (

[GENERAL] error linking with PostgreSQL

2009-11-22 Thread Daniel
Here is the code: #include "libpq-fe.h" #ifndef HDBUTIL #define HDBUTIL class DBConn { public: PGconn pg_conn; bool Connect(); bool Disconnect(); }; #endif ... and here is the make error: tux tb # make g++ -Wall -g -o0 -lpq -I/usr/include/postgresql/libpq-4 server.cpp d