"David G. Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com> writes:
> I think you just wrote the equivalent of:
> l_cnt := (select 1 as delete from foo3 where id=1);
> Which is a valid query.
Still another example of the folly of letting AS be optional.
I don't suppose we can ever undo that though.
regards, tom lane