Patch for cursor calling with named parameters

Yeb Havinga <yebhavinga@gmail.com>

From: Yeb Havinga <yebhavinga@gmail.com>
To: pgsql-hackers@postgreSQL.org
Date: 2011-09-15T08:18:12Z
Lists: pgsql-hackers

Attachments

Hello list,

The following patch implements cursor calling with named parameters in 
addition to the standard positional argument lists.

c1 cursor (param1 int, param2 int) for select * from rc_test where a > 
param1 and b > param2;
open c1($1, $2);                     -- this is currently possible
open c1(param2 := $2, param1 := $1); -- this is the new feature

Especially for cursors with a lot of arguments, this increases 
readability of code. This was discussed previously in 
http://archives.postgresql.org/pgsql-hackers/2010-09/msg01433.php. We 
actually made two patches: one with => and then one with := notation. 
Attached is the patch with := notation.

Is it ok to add it to the next commitfest?

regards,
Yeb Havinga, Willem Dijkstra

-- 
Yeb Havinga
http://www.mgrid.net/
Mastering Medical Data