disable trigger all

Started by Grzegorz Jaśkiewiczover 15 years ago3 messagesgeneral
Jump to latest
#1Grzegorz Jaśkiewicz
gryzman@gmail.com

I got bitten Today by 'alter table disable trigger all' vs 'trigger user'.
Basically , assuming that psql doesn't show me that FKs are disabled
some code was using 'trigger all' instead of 'user'.

Is that a bug of psql, or a feature ? As far as I can see
pg_catalog.pg_constraint doesn't contain information about whether FK
is disabled as a result of trigger disabling query or not. So it is
hard to asses the damage as well.

--
GJ

#2Tom Lane
tgl@sss.pgh.pa.us
In reply to: Grzegorz Jaśkiewicz (#1)
Re: disable trigger all

=?UTF-8?Q?Grzegorz_Ja=C5=9Bkiewicz?= <gryzman@gmail.com> writes:

I got bitten Today by 'alter table disable trigger all' vs 'trigger user'.
Basically , assuming that psql doesn't show me that FKs are disabled
some code was using 'trigger all' instead of 'user'.

I think that is today's lesson in why not to work as a superuser except
when you absolutely have to.

regards, tom lane

#3Grzegorz Jaśkiewicz
gryzman@gmail.com
In reply to: Tom Lane (#2)
Re: disable trigger all

2010/9/29 Tom Lane <tgl@sss.pgh.pa.us>:

=?UTF-8?Q?Grzegorz_Ja=C5=9Bkiewicz?= <gryzman@gmail.com> writes:

I got bitten Today by 'alter table disable trigger all' vs 'trigger user'.
Basically , assuming that psql doesn't show me that FKs are disabled
some code was using 'trigger all' instead of 'user'.

I think that is today's lesson in why not to work as a superuser except
when you absolutely have to.

Thanks :)
Somehow I knew, you're not going to say. 'Ya, this is a bug, that info
should be displayed to the user'.

--
GJ