Re: statement_timeout vs DECLARE CURSOR

2021-09-28 Thread Tom Lane
I wrote: > Christophe Pettus writes: >> A bit more poking revealed the reason: The ON HOLD cursor's query is >> executed at commit time (which is, logically, not interruptible), but that's >> all wrapped in the single statement outside of a transaction. > Hmm ... seems like a bit of a UX failur

Re: statement_timeout vs DECLARE CURSOR

2021-09-27 Thread Tom Lane
Christophe Pettus writes: >> On Sep 27, 2021, at 10:42, Christophe Pettus wrote: >> We've encountered some unexpected behavior with statement_timeout not >> cancelling a query in DECLARE CURSOR, but only if the DECLARE CURSOR is >> outside of a transaction: > A bit more poking revealed the rea

Re: statement_timeout vs DECLARE CURSOR

2021-09-27 Thread Christophe Pettus
> On Sep 27, 2021, at 10:42, Christophe Pettus wrote: > We've encountered some unexpected behavior with statement_timeout not > cancelling a query in DECLARE CURSOR, but only if the DECLARE CURSOR is > outside of a transaction: A bit more poking revealed the reason: The ON HOLD cursor's quer

statement_timeout vs DECLARE CURSOR

2021-09-27 Thread Christophe Pettus
Hi, We've encountered some unexpected behavior with statement_timeout not cancelling a query in DECLARE CURSOR, but only if the DECLARE CURSOR is outside of a transaction: xof=# select version(); version