Anand <anand@blandings.com> writes:
> When I run the select statement given below, the postgres server dies on
> a SIGSEGV. This is quite annoying.
Hmm ... works for me.
You should check that the plpgsql.so mentioned by the CREATE FUNCTION
call is the same version of Postgres as your backend. Weird things can
happen if an out-of-date plpgsql.so gets loaded. I have not seen this
particular behavior reported before, though, so maybe that's not it.
regards, tom lane