Re: review: CHECK FUNCTION statement

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: review: CHECK FUNCTION statement
Дата
Msg-id 1330698977-sup-2483@alvh.no-ip.org
обсуждение исходный текст
Ответ на Re: review: CHECK FUNCTION statement  (Pavel Stehule <pavel.stehule@gmail.com>)
Ответы Re: review: CHECK FUNCTION statement
Список pgsql-hackers
Excerpts from Pavel Stehule's message of vie mar 02 05:29:26 -0300 2012:

> you cannot to check trigger function without assigned relation -
> TupleDescription should be assigned to NEW and OLD variables.

Oh, I see, that makes sense.

After mulling over this a bit, I'm dubious about having two separate
commands, one which checks triggers and another that checks non-trigger
functions.  Wouldn't it make more sense to have some options into CHECK
FUNCTION so that it receives the trigger and corresponding relation name
to check?  For example "check function foo() trigger on tab" or
something like that?

I also wonder if it would make sense to have grammar for "check all
triggers on table xyz" or some such, and even "check all triggers on all
functions".

Another thing is that "CHECK FUNCTION ALL FOR ROLE foo" seems a bit
strange to me.  What about "CHECK FUNCTION ALL OWNED BY foo" instead?
("CHECK FUNCTION ALL" seems strange as a whole, but I'm not sure that we
can improve that ... still, if anyone has ideas I'm sure we can discuss)

As a reminder: we also have
CHECK FUNCTION ALL IN SCHEMA f
and
CHECK FUNCTION ALL IN LANGUAGE f
(and combinations thereof)

Thoughts?

--
Álvaro Herrera <alvherre@commandprompt.com>
The PostgreSQL Company - Command Prompt, Inc.
PostgreSQL Replication, Consulting, Custom Development, 24x7 support


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: autovacuum locks
Следующее
От: Gilles Darold
Дата:
Сообщение: Re: Patch pg_is_in_backup()