Re: [BUGS] BUG #7881: SQL function failures in long-lived calling contexts

2013-03-03 Thread Tom Lane
I wrote: > Or we could add fields recording the current transaction/subtransaction > IDs, then throw away and regenerate the function cache entry if that > subxact is no longer active. This would be a bit more invasive/riskier > than throwing a "not supported" error, but it would preserve the > fu

Re: [BUGS] BUG #7881: SQL function failures in long-lived calling contexts

2013-03-03 Thread Tom Lane
and...@tao11.riddles.org.uk writes: > The SQL function handler, fmgr_sql, isn't prepared to deal with the > possibility that the fcache entry may be left over from a previous query > that failed. Yeah. The immediate cause of that failure is that it supposes that it's continuing execution of the S