Without seeing the code, maybe try to put the query in a string variable and then pass variable.c_str() to exec, and see if that helps.Message: 4 Date: Tue, 13 Jun 2006 13:55:47 +0200 (CEST) From: [EMAIL PROTECTED] Subject: [libpqxx-general] Problem with dynamically built queries To: [email protected] Message-ID: <[EMAIL PROTECTED]> Content-Type: text/plain;charset=iso-8859-1 Hi all, Iencounter some obvious stupid problem... I'd like to make something like select * from my_table where id=<my_id> the string is built using ostringstream with << C++ operator The query is good, pasted into the psql interpreter runs fine but fails with a syntax error in my code ... I thought about any special character but it would be a problem after a paste in the postgres console too.. any idea welcome...
|
Chris -- Sometimes I wonder whether the world is being run by smart people who are putting us on or by imbeciles who really mean it. -- Mark Twain |
_______________________________________________ Libpqxx-general mailing list [email protected] http://gborg.postgresql.org/mailman/listinfo/libpqxx-general
