From: "Cobus Carstens" <cobus(dot)carstens(at)swistgroup(dot)com>
To: <pgsql-interfaces(at)postgresql(dot)org>
Subject:
Date: 2003-10-28 05:45:42
Message-ID: DEC925D2FB9081448C3D6EC26E85868CF81404@steinmail.swistgroup.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-interfaces


Hi there.

I'm running Postgresql 7.3.2 on Mandrake 9.1.
I'm using ecpg (version 2.10.0) to compile the embedded sql code in my C
programs.

The problem experienced has to do with array indexing in SQL statements.
I browsed your test files in the CVS repository and found one
(http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/interfaces/
ecpg/test/test1.pgc?rev=1.31.2.1&content-type=text/x-cvsweb-markup) that
contains the code I would like to be able to use.

When I precompile the abovementioned file with ecpg, I get the following
error
test1.pgc:130: parse error at or near "[".

It is the same problem I'm experiencing with my program. I tested my
program on Postgresql 7.3.4 as well, but it also did not work (the ecpg
version was the same as the 7.3.2's).

What do you suggest I do to get this working? Grab latest code from CVS?

My second question is with regards to Oracle style bulk inserts/updates.
I've played around with the "COPY" command and it seems to have good
performance (even though I have to explicitly sprintf all values in a
string first). I'm currently working on a port of existing software that
stores huge amounts of (telecoms) data, so performance is critical. Is
there any special way of handling a lot of updates? I can understand
that updates might need to be done one at a time, but it would be nice
if I can cut out the overhead of calling an update sql statement
repeatedly - I'm thinking in the line of the Oracle bulk updates where
you give the sql statement and host arrays containing the fieldvalues
for the different updates.

Any hints/suggestions would be appreciated.

Regards,
Cobus Carstens

Responses

  • Re: at 2003-10-31 09:58:54 from Michael Meskes

Browse pgsql-interfaces by date

  From Date Subject
Next Message Tom Lane 2003-10-29 18:33:09 Re: pgtcl large object read/write corrupts binary data
Previous Message Surasak Khun 2003-10-28 05:17:44 Question on using fonts and run pgaccess on Windows XP