Bruce Momjian <pgman@candle.pha.pa.us> writes:
> *** src/backend/commands/vacuum.c 12 Apr 2002 20:38:25 -0000 1.223
> --- src/backend/commands/vacuum.c 14 Apr 2002 16:41:37 -0000
> ***************
> *** 181,186 ****
> --- 181,189 ----
> if (IsTransactionBlock())
> elog(ERROR, "%s cannot run inside a BEGIN/END block", stmttype);
> + if (!MemoryContextContains(QueryContext, vacstmt))
> + elog(ERROR, "VACUUM cannot be executed from a function");
> +
> /*
> * Send info about dead objects to the statistics collector
> */
> --ELM1018803173-10746-0_--
Compare to immediately preceding error check. Isn't there something
missing here?
regards, tom lane