Re: Trigger disactivation and SELECT WAITING

From: "Philippe Lang" <philippe(dot)lang(at)attiksystem(dot)ch>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>, <pgsql-general(at)postgresql(dot)org>
Subject: Re: Trigger disactivation and SELECT WAITING
Date: 2005-07-26 14:07:21
Message-ID: 6C0CF58A187DA5479245E0830AF84F42143574@poweredge.attiksystem.ch
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi,

I meant: in 7.4.X databases, is there a way of disabling a trigger without deleting it? I guess the answer is no.

That's what my plpgsql insert function does, and because of this, if a view is running at the same moment on the same tables (some views can take up to 2 hours to be calculated), the insert function gets stuck in a SELECT WAITING state. So insertions are impossible in the database when views are being calculated.

Regards,

-----Message d'origine-----
De : Tom Lane [mailto:tgl(at)sss(dot)pgh(dot)pa(dot)us]
Envoyé : mardi, 26. juillet 2005 15:14
À : Philippe Lang
Cc : pgsql-general(at)postgresql(dot)org
Objet : Re: [GENERAL] Trigger disactivation and SELECT WAITING

"Philippe Lang" <philippe(dot)lang(at)attiksystem(dot)ch> writes:
> I have a database with views that can take up to 2 hours to be
> calculated.

> During that time, it's not possible to run a function that inserts
> data into the database, apparently because this function disactivates
> a trigger while it runs, by deleting and creating the trigger again at
> the end. (At least in 7.4.X database, this is the only solution,
> right?)

"Only solution" to what? Why in the world would a view fool around with removing triggers?

regards, tom lane

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Marco Colombo 2005-07-26 14:08:31 Re: RAMFS with Postgres
Previous Message Richard Huxton 2005-07-26 13:55:35 Re: Access FE - This operation is not supported within