Peter Eisentraut wrote:
Josh Berkus wrote:
Dennis has pointed out that mixing the call-with-named-parameterAs we've discussed on IRC, this should be the difference between a
interface with call-by-order-of-parameters one would cause
confusion, and I think it would be OK to disallow this type mixing,
so
FUNCTION and a PROCEDURE.
Huh? As far as I can tell, the difference between a function and a procedure is precisely that the latter doesn't return a value. A consistent way to specify the parameters of either one would certainly be highly desirable.
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.
I think you're right on both counts.
ISTM we need a more strategic discussion of where we want to go with procedural code.
some other ideas to consider:
- it would be nice to be able to say PERFORM 'string with plcode' language plname;
- OUT / INOUT parameters
I think we need an idea of where we are going with all this stuff, rather than approaching the area piecemeal in a way that might preclude other decisions we might want to make later.
cheers
andrew
---------------------------(end of broadcast)--------------------------- TIP 7: don't forget to increase your free space map settings