Tom Lane wrote:
>
> Weiping He <laser@zhengmai.com.cn> writes:
> > it seems PERFORM won't affect result status while doing
> > SELECT ... query, but EXECUTE do.
>
> It works for me.
>
> > raise notice '' SQL: % '', qry;
> > -- execute qry;
> > perform qry;
>
> This should give you an error. perform doesn't take a string
> expression. You want something more like
>
> perform t FROM test where ...
PERFORM was originally added because we have no resultless procedures,
only functions, and calling a function with SELECT and discarding the
result seemed unobvious, so PERFORM does exactly that for you. It's
useless syntactic sugar.
Jan
--
#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me. #
#================================================== JanWieck@Yahoo.com #