2009/9/16 Tom Lane :
> =?UTF-8?Q?Grzegorz_Ja=C5=9Bkiewicz?= writes:
>> Looks like psql loves to report on errors, only when -c is used,
>> otherwise return code is always 0...
>
> The documentation seems perfectly clear on this point:
>
> psql returns 0 to the shell if it finished normally, 1 if a
=?UTF-8?Q?Grzegorz_Ja=C5=9Bkiewicz?= writes:
> Looks like psql loves to report on errors, only when -c is used,
> otherwise return code is always 0...
The documentation seems perfectly clear on this point:
psql returns 0 to the shell if it finished normally, 1 if a fatal error of its
own (out o
http://gj.pastebin.com/f119e67bc
Looks like psql loves to report on errors, only when -c is used,
otherwise return code is always 0...
I tested 8.3 and cvs-head, both have the same issue.
Is that the 'by design' (bug/feature) ?
--
GJ
--
Sent via pgsql-general mailing list (pgsql-general@pos
On Mon, 10 Nov 2008 10:56:57 +
Richard Huxton <[EMAIL PROTECTED]> wrote:
> Ivan Sergio Borgonovo wrote:
> > I'm running:
> >
> > ON_ERROR_STOP="on" PGPASSFILE="/somewhere" psql dbname username
> > -f script.sql
> > (or alternatively >
> > echo $?
> > always returns 0 even when sql is clearl
Ivan Sergio Borgonovo wrote:
> I'm running:
>
> ON_ERROR_STOP="on" PGPASSFILE="/somewhere" psql dbname username -f
> script.sql
> (or alternatively
> echo $?
> always returns 0 even when sql is clearly wrong.
I don't think ON_ERROR_STOP is read from the environment, you need to
define it as a p
I'm running:
ON_ERROR_STOP="on" PGPASSFILE="/somewhere" psql dbname username -f
script.sql
(or alternatively http://www.webthatworks.it
--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general