Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WDZZD-0005qG-RK for pgsql-bugs@arkaria.postgresql.org; Wed, 12 Feb 2014 13:09:32 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1WDZZD-0004FA-9r for pgsql-bugs@arkaria.postgresql.org; Wed, 12 Feb 2014 13:09:31 +0000 Received: from makus.postgresql.org ([2001:4800:7903:4::125]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WDZZB-0004DZ-Md for pgsql-bugs@postgresql.org; Wed, 12 Feb 2014 13:09:29 +0000 Received: from feynman.df7cb.de ([2001:6f8:10ee::1]) by makus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WDZZ8-00051n-Ih for pgsql-bugs@postgresql.org; Wed, 12 Feb 2014 13:09:29 +0000 Received: from msgid.df7cb.de (benz.df7cb.de [IPv6:2001:6f8:10ee:e:134::2]) (using TLSv1.2 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (Client did not present a certificate) by feynman.df7cb.de (Postfix) with ESMTPSA id 76160696B7 for ; Wed, 12 Feb 2014 14:09:23 +0100 (CET) Date: Wed, 12 Feb 2014 14:09:22 +0100 From: Christoph Berg To: pgsql-bugs@postgresql.org Subject: Re: BUG #9198: psql -c 'SET; ...' not working Message-ID: <20140212130922.GC4409@msgid.df7cb.de> Mail-Followup-To: Christoph Berg , pgsql-bugs@postgresql.org References: <20140212125626.2710.94912@wrigleys.postgresql.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="/Uq4LBwYP4y1W6pO" Content-Disposition: inline In-Reply-To: <20140212125626.2710.94912@wrigleys.postgresql.org> User-Agent: Mutt/1.5.21 (2010-09-15) X-Pg-Spam-Score: -2.6 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org --/Uq4LBwYP4y1W6pO Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Re: To pgsql-bugs@postgresql.org 2014-02-12 <20140212125626.2710.94912@wrig= leys.postgresql.org> > time psql -c "SET statement_timeout =3D '3s'; SELECT pg_sleep(2)" > ERROR: canceling statement due to statement timeout > real 0m1.065s >=20 > 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. >=20 > 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 --=20 cb@df7cb.de | http://www.df7cb.de/ --/Uq4LBwYP4y1W6pO Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBCAAGBQJS+3KAAAoJEExaa6sS0qeuDOAP/iJbMh9jz3QS60hNKko2eani Yl1eFSFOGt2YOxEzeDxTHB64Hi2ZV0UXXZmXVi7SEJ+bTStXJHcVO9c2F/ZjSZYu ED40UtVRDyrUQY57Nb49rBbwdad8AZ6dKRchdY0fTNxZt2SBx1J/3uvzVSlm8NLK qttMF0sB0TL0ImBCd2CE087VtsNKhhNHp8OxOOx7cJE0mQVOmCSvpsL78c/j6PaJ +5mylKkhOLAa6ObNuF0SEi7bmmh24rqiXMnja12gxPhklE85eKBaLh2DYr29nFRY 6ipDKFUEz/7jB0GaRww6967dDkLuEPBXHicVBt1kFCS9VETF6jJQUFTNxcCFLOOH eOdO2aoHpnjpT9ru0xlLDxU0slNVLwVwkgHXbzAGrNQ4nlTIKlM9BLpsWXANBEik inKvCLHhoGkaPRmEHep/zWovjzxr5PfpmMxVvboK3YONRnE67eQzwy8qGDpE1+vq z6K7yn3JuZrId3nPV/O1SEVdrxUIJnC9YLiy0wiS7GGlne9Luer1Xc7N6Jhg9i/e 9/hBmL0+fucMaKAAVtPfKJB+k+L9MULPONJbhFh0/AJyvGWP8OshPP7uPG9rjKby hYoXZTYH79G86CryZaX1IxiSDX2P5lrwFKHKTvBQD6WJje5qWfYceD5n6BvV01ID kxEI2ySvyZWvur79RNaF =JoIq -----END PGP SIGNATURE----- --/Uq4LBwYP4y1W6pO--