Alfonso Peniche <alfonso(at)iteso(dot)mx> writes:
> What's wrong with this function? The syntax is supposed to be right,
> isn't it?
No, it isn't right, not for plpgsql. SELECT INTO means something
different to plpgsql than it does in normal Postgres SQL.
regards, tom lane