Re: statement_timeout doesnt work within plpgsql by design?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Robert Treat <xzilla(at)users(dot)sourceforge(dot)net>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: statement_timeout doesnt work within plpgsql by design?
Date: 2007-02-20 17:50:28
Message-ID: 7211.1171993828@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Robert Treat <xzilla(at)users(dot)sourceforge(dot)net> writes:
> pagila=# create or replace function test() returns bool as $$ begin set
> statement_timeout = 3000; perform pg_sleep(4) ; return true; end $$ language
> plpgsql;
> CREATE FUNCTION

statement_timeout is measured across an entire interactive command, not
individual commands within a function; and the timeout that applies to
an interactive command is determined at its beginning. So the above
doesn't do what you think.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message RPK 2007-02-20 18:27:39 Re: New feature request: FlashBack Query
Previous Message Robert Treat 2007-02-20 17:00:53 statement_timeout doesnt work within plpgsql by design?