On 4/10/07, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> "Nikolay Samokhvalov" <nikolay(at)samokhvalov(dot)com> writes:
> > I remember several cases when people (e.g. me :-) ) were spending some
> > time trying to find an error in some pl/pgsql function and the reason
> > lied in incorrect work with arrays (i.e. messages like "index is out
> > of bounds" and "index cannot be negative number" would help, surely).
>
> Well, if indexes *couldn't* be negative numbers then that might be
> helpful, but they can.
>
Ooops :-) OK, my proposal is narrowing to very simple one: what about
triggering WARNINGs when user tries to access nonexistent element of
array?
--
Best regards,
Nikolay