From: Christoph Berg <christoph.berg@credativ.de>
To: pgsql-bugs@postgresql.org
Subject: Re: BUG #9198: psql -c 'SET; ...' not working
Date: Wed, 12 Feb 2014 14:09:22 +0100
Message-ID: <20140212130922.GC4409@msgid.df7cb.de> (raw)
In-Reply-To: <20140212125626.2710.94912@wrigleys.postgresql.org>
References: <20140212125626.2710.94912@wrigleys.postgresql.org>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>
Re: To pgsql-bugs@postgresql.org 2014-02-12 <20140212125626.2710.94912@wrigleys.postgresql.org>
> time psql -c "SET statement_timeout = '3s'; SELECT pg_sleep(2)"
> ERROR: canceling statement due to statement timeout
> real 0m1.065s
>
> As witnessed by the time output, the timeout is the one from ALTER ROLE, not
> the new one. Seen on 9.2 and 9.3.
>
> The psql docs mention that -c is treated differently from stdin when
> multiple commands are executed, but that shouldn't include SET not getting
> into effect.
The same problem occurs with statement_timeout from postgresql.conf
and from PGOPTIONS.
Christoph
--
cb@df7cb.de | http://www.df7cb.de/Attachments:
signature.asc (application/pgp-signature, 818B) download
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: christoph.berg@credativ.de
Subject: Re: BUG #9198: psql -c 'SET; ...' not working
In-Reply-To: <20140212130922.GC4409@msgid.df7cb.de>
References: <20140212125626.2710.94912@wrigleys.postgresql.org> <20140212130922.GC4409@msgid.df7cb.de>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox