Re: psql return codes
| От | Tom Lane |
|---|---|
| Тема | Re: psql return codes |
| Дата | |
| Msg-id | 184.1165433146@sss.pgh.pa.us обсуждение |
| Ответ на | Re: psql return codes (Bruce Momjian <bruce@momjian.us>) |
| Ответы |
Re: psql return codes
|
| Список | pgsql-hackers |
Bruce Momjian <bruce@momjian.us> writes:
> Jim C. Nasby wrote:
>> Why should it matter if the "SELECT * FROM foo" came to
>> psql via -f or -c?
> Well, it explains exactly what Simon was seeing. I agree it is strange,
> but I was asking if Simon knew it was documented. I assume the "3" is
> used to report a different error from 'file not found' or something.
Well, the real point here is that ON_ERROR_STOP doesn't apply to
interactive input, and -c is evidently being considered to be
interactive. You could argue that either way I suppose, but seeing
that -c can only issue a single command, implementing ON_ERROR_STOP
for it seems like largely a waste of effort.
regards, tom lane
В списке pgsql-hackers по дате отправления: