Peter Eisentraut <peter_e@gmx.net> writes:
> Josh Berkus wrote:
>> b) Procedures are not automatically transactional; that is,
>> transactions within procedures must/can be explicit. Among other
>> things, this would allow procedures to run maintainence tasks.
> I certainly want all my maintenance tasks to be transactional. Being
> nontransactional is a fuzzy idea anyway. You can't really run anything
> without a transaction in PostgreSQL.
Yeah, but the point is that a procedure in these terms could start and
end transactions. Right now, any process you want to perform that has
to span more than one transaction has to be driven by client-side code.
It *would* be nice to be able to encapsulate such things totally on the
server side. The actual work would of course all be inside
transactions, but if we could have (some limited amount of) control
logic outside it would be a nice addition.
I agree however with Andrew's nearby point that this is completely
unrelated to named parameters to functions/procedures, or to defaults
for parameters.
regards, tom lane