[Libpqxx-general] Creating a connection object

Vincent Predoehl vpredoehl at phoenixwebgroup.com
Fri Jun 13 00:37:34 UTC 2008


On Jun 12, 2008, at 3:11 PM, Jeroen Vermeulen wrote:

> Vincent Predoehl wrote:
>> I'm want to use libpqxx integration in my app.  The tutorial says  
>> to create a connection using:
>> connection Conn("dbname=test");
>> The correct header to use appears to be #include <pqxx/ 
>> connection>, but I get this compile error:
>> /usr/local/include/pqxx/basic_connection.hxx:45: error:  
>> redefinition of 'class pqxx::basic_connection<CONNECTPOLICY>'
>> /usr/local/include/pqxx/basic_connection.hxx:47: error: previous  
>> definition of 'class pqxx::basic_connection<CONNECTPOLICY>'
>
> That line above is supposed to work.  Did you configure and build  
> libpqxx yourself, or did you use a packaged version for your platform?

I have have MacOS X, libpqxx-2.6.9 and I built it myself using  
powerpc-apple-darwin8-gcc-4.0.1:.  I believe all I did was

./configure
make
sudo make install

I will attempt to locate the package and see if that works.

> Also, what libpqxx and gcc version are you using?  (The errors look  
> like gcc ones, so I'm assuming that's what you use).
>
>
> Jeroen

-- VP



-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://pgfoundry.org/pipermail/libpqxx-general/attachments/20080612/af9e2a5f/attachment.html 


More information about the Libpqxx-general mailing list