When I copied the code from my linux box I hadn't made the reference changes yet (which have since been made). I log the sql exception and show the actualy sql that caused the exception and it showed the sql I pushed in "select * from items". This code HAD worked under FC3. I will take a look at lazyconnection, maybe that will work.
My best guess is that there is some old remnant lying around from FC3 that is getting linked in vs something newer in FC6. The problem is that I don't know what since I either rebuilt or forced an update on all known components. I changed "DemoTransaction" to "demotransaction" but that didn't fix it. Thanks for helping! -----Original Message----- From: Jeroen T. Vermeulen [mailto:[EMAIL PROTECTED] Sent: Friday, November 17, 2006 10:58 AM To: Kevin Lambert Cc: [email protected] Subject: Re: [libpqxx-general] pqxx::sql_error on "SELECT * FROM ITEMS" On Fri, November 17, 2006 20:51, Kevin Lambert wrote: > My bad. I was retyping code into the email that I was looking at via > VNC on the linux box which is why it got a bit mangled. I was finally > able to transfer it over (had to restart Eclipse). I yanked extra > stuff that doesn't matter (logging, etc). Thanks for making the effort. Hope we can get this resolved soon. > try { > if ( conn == NULL ) { > conn = new connection("dbname=testdb user=postgres"); > > work Xaction(*conn, "DemoTransaction"); > result R = Xaction.exec("select * from items"); This looks just fine to me (though do check out the lazyconnection class to save yourself the trouble of allocating the connection dynamically). Can't see anything that could possibly cause any trouble, except perhaps the upper-case letters in the transaction name. As I said though, that probably doesn't change anything. > } catch(pqxx::sql_error sqlE) { > > return false; > } catch (pqxx::broken_connection bcE) { Careful--there's the "non-reference catch clauses" again! I've tried your program (or as much of it as I could reproduce) on a Fedora 6 as installed from CD, and found no problems. That was using my own compile of libpqxx, but everything else as it came with Fedora. I'll try to download all updates and install libpqxx, then test again. That will have to be after the weekend though! One question, probably silly but better safe than sorry: are you quite, quite sure that the problem happens in this piece of code, not somewhere else? Jeroen _______________________________________________ Libpqxx-general mailing list [email protected] http://gborg.postgresql.org/mailman/listinfo/libpqxx-general
