X-Original-To: pgsql-interfaces-postgresql.org@localhost.postgresql.org Received: from localhost (neptune.hub.org [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 181EDD1B470 for ; Sun, 21 Dec 2003 22:52:06 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 30977-05 for ; Sun, 21 Dec 2003 18:51:18 -0400 (AST) Received: from VL-MO-MR005.ip.videotron.ca (relais.videotron.ca [24.201.245.36]) by svr1.postgresql.org (Postfix) with ESMTP id B2AC3D1B43C for ; Sun, 21 Dec 2003 18:51:10 -0400 (AST) Received: from mailinator.com ([69.70.81.159]) by VL-MO-MR005.ip.videotron.ca (iPlanet Messaging Server 5.2 HotFix 1.21 (built Sep 8 2003)) with ESMTP id <0HQ9004Y1OLADZ@VL-MO-MR005.ip.videotron.ca> for pgsql-interfaces@postgresql.org; Sun, 21 Dec 2003 17:46:22 -0500 (EST) Date: Sun, 21 Dec 2003 16:45:08 -0500 From: Carlos Moreno Subject: C++ with PG 7.4? To: pgsql-interfaces@postgresql.org Message-id: <3FE61464.4050303@mailinator.com> MIME-version: 1.0 Content-type: text/plain; charset=us-ascii; format=flowed Content-transfer-encoding: 7BIT X-Accept-Language: en-us, en User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.5) Gecko/20031007 X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200312/44 X-Sequence-Number: 4653 Hi, I see that version 7.4 introduces new features in the client API area -- error codes, for instance. So, I'm wondering if this will affect the way libpq++ works; assuming that the SQL's don't use any feature that has changed with version 7.4, should I expect any difference in code that uses straightforward things like the following: PgDatabase db ("host=blah.blah.com user=me dbname=db password=me"); if (db.ConnectionBad()) { .... } if (db.Exec ("select .... from ....") != PGRES_TUPLES_OK) { for (int i = .... db.Tuples() ....) { .... db.GetValue (i, "field_name") .... ; } } if (db.Exec ("insert into ..... ") != PGRES_COMMAND_OK) { .... } I'm guessing that I would be able to use new features and new error codes, but if I keep my programs the same (with the old set of defined constants, etc.), they will work the same? (again, assuming that the SQL's don't use any feature for which the behaviour of the backend has changed with ver 7.4) Also, are there any plans to re-include C++ client API as part of the postgresql package? I don't mean to sound ungrateful for everything that PostgreSQL offers, but I do believe that removing C++ from the default distribution was a great disservice to the community -- partly because libpq++ does not even compile without some fine tuning (well, programs written with it don't compile -- at least on RedHat). According to a survey you did a while ago, C++ had 2 or 3 times more users than C (off the top of my head -- I couldn't access the "survey results" page, to check those numbers). I must admit to some personal bias in favor of C++, but still, it's not like C++ is some obscure useless niche language that only a few weirdos have heard of. Thoughts, comments? Thanks, Carlos --