[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Gnumed-devel] bootstrap_db
From: |
Horst Herb |
Subject: |
Re: [Gnumed-devel] bootstrap_db |
Date: |
Fri, 15 Nov 2002 15:07:16 +0100 |
User-agent: |
KMail/1.4.3 |
On Thu, 14 Nov 2002 11:31, Karsten Hilbert wrote:
> Python script via a pipe. But alas, contrary to the man page,
> psql does NOT return an errorlevel of 3 upon receiving an
> format definition error (bad SQL, usually) from the backend.
> Thus the Python script cannot reliably detect whether things
> failed or not (short of parsing the output for "ERROR" which
> is hardly elegant).
>
> Anyone having any suggestions ?
It probably depends on the status of ON_ERROR_STOP; if it is not set, psql
just prints the error messages but does not bail out with an error code (my
guess)
Horst