"Celia McInnis" <celia(at)drmath(dot)ca> writes:
> but how do I access members of this array individually??? I'd love it if
> direction[1] would pull out the 2nd or 1st element so that I could use it in
> the selects which my procedure is forming, but I get syntax errors when I try
> to reference the array element in such a way. For example:
> RAISE NOTICE '%',direction[1];
> ERROR: syntax error at or near "[" at character ####
The RAISE statement is pretty limited: it won't take a general
expression as an argument, only a bare variable name. But you should be
able to subscript direction in other contexts. If you really need to
put out a notice using this value, assign it to a temporary variable ...
regards, tom lane