Hello, I am having trouble using libpqxx's connection. It may be a
misunderstanding on my part.
I want a persistent connection, a connection to postgresql database
server I can use throughout the lifetime of my program. As we know,
connecting and disconnecting from a server can be expensive. It seems I
simply cann't do this with libpqxx. For example,
#include <pqxx/pqxx>
class mydbh{
private:
pqxx::connection c;
public:
mydbh(){
c = pqxx::connection("");
}
};
I simply can't compile this code due to connection class design
decision. Is there a workaround of this problem? Or am I missing
something completely?
Thanks,
Fei
_______________________________________________
Libpqxx-general mailing list
[email protected]
http://gborg.postgresql.org/mailman/listinfo/libpqxx-general