Statement_timeout in procedure block - Mailing list pgsql-admin

From Teja Jakkidi
Subject Statement_timeout in procedure block
Date
Msg-id E0175C30-9A8F-4648-A2D5-36908FF6F695@gmail.com
Whole thread Raw
Responses Re: Statement_timeout in procedure block
Re: Statement_timeout in procedure block
Re: Statement_timeout in procedure block
List pgsql-admin
Hello PgAdmins,

We have a Postgres instance where we had set statement_timeout to 1hour at instance level.
However, today we noticed that one of our cron jobs which calls a stored procedure failed with timeout error as it was
runningfor more than an hour. 
I tried setting “Set local statement_timeout=‘2 h’” within the stored procedure expecting that the statement timeout
willbe 2hours for the SP execution. However it did not work as expected.  
Can anyone please suggest what can be done here.

Thanks in advance,
J. Teja.


pgsql-admin by date:

Previous
From: "Vitale, Anthony, Sony Music"
Date:
Subject: RE: Scripting a ALTER PROCEDURE or FUNCTION to Change OWNER
Next
From: Wells Oliver
Date:
Subject: Materialized views & dead tuples