Re: [HACKERS] ecpg news - Mailing list pgsql-hackers

From Thomas G. Lockhart
Subject Re: [HACKERS] ecpg news
Date
Msg-id 34F2CEE1.E702CC35@alumni.caltech.edu
Whole thread Raw
In response to ecpg news  (Michael Meskes <meskes@topsystem.de>)
Responses Re: [HACKERS] ecpg news  (Michael Meskes <meskes@topsystem.de>)
List pgsql-hackers
> Also, I'm not sure about what the standard says for the whenever command.
> I'm pretty sure I already saw a 'exec whenever sqlerror break;' command
> maybe on Ingres. Oracle does not know about this. I tried implementing it
> regardless, but found that this is almost impossible since break obviously
> cannot be issued outside a loop resp. switch statement. Shall I just remove
> it?

The CA-Ingres parameters on "whenever" are only "continue", "stop", "goto
<label>", and "call <procedure>". I suspect that part of the problem is that
embedded SQL is available for several host languages, and some don't map the
same way as C would. How about disabling it for now?

> And the continue statement? Currently ecpg adds a continue command, but it
> appears to be better to do nothing in case the user wants to continue. This
> is btw what Oracle does too.

CA-Ingres sez:continue: continues execution with the next executable statement.
If a fatal error occurs, an error message is printed and the program aborts.

I think this means that errors are ignored, as in Oracle, rather than doing a
C-style "continue". Then, the program can check the sqlcode variable to decide
what to do...

> Finally, here's a list of open bugs that I won't be able to tackle before
> 6.3 is released:

The embedded SQL is a great capability which was one of the most visible
omissions in the Postgres features. Thanks for being so aggressive and
persistent about getting it solid for its first release. But, we've got to have
a few things to work on later :)

                                              - Tom


pgsql-hackers by date:

Previous
From: Frank Ridderbusch
Date:
Subject: Using the -u switch for diff in regress.sh
Next
From: "Vadim B. Mikheev"
Date:
Subject: some problems with new locking code