Hello list,

We intend to implement $subject, so instead of

mycursor CURSOR (myparm text) IS SELECT myparm;
OPEN mycursor('A');

it would be possible to do

OPEN mycursor(myparm := 'A');

The idea is to

* in pl_exec.exec_stmt_forc, detect if a positional parameter or named parameter is used. * if named, use plpgsql_ns_lookup to find the cursur arguments position in the plpgsql name space.
* normal processing for the found position from here.

Mixing named and positional could probably be made to work as well.

Does this approach sound reasonable?

regards,
Yeb Havinga & Willem Dijkstra


--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to