| From: | Mario Medina <mario(at)soweb(dot)com(dot)mx> | 
|---|---|
| To: | pgsql-php(at)postgresql(dot)org | 
| Subject: | disabling triggers temporaly | 
| Date: | 2006-06-02 04:54:28 | 
| Message-ID: | 447FC484.3090301@soweb.com.mx | 
| Views: | Whole Thread | Raw Message | Download mbox | Resend email | 
| Thread: | |
| Lists: | pgsql-php | 
Hi! does it exists any way to make that a trigger be disabled only for 
one insert and for other inserts not?
I have a table, every insert,update or delete on it activates a trigger 
that do some tasks, but i wish that when i call special 
insert/update/delete on that table the trigger doesn't starts...
The only way i think to do that is to start a transaction, delete the 
trigger, do the insert on the table, create the trigger again an commit 
the transaction..., and another is to make the trigger to check some 
value, and if that value is 1 the trigger works, if it is 0 the trigger 
doesn't, but i wish to know if it is a better way.
Thank you.
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Josh Berkus | 2006-06-02 17:47:31 | Re: php|works / db|works call for papers ends June | 
| Previous Message | Robert Treat | 2006-06-02 04:26:26 | php|works / db|works call for papers ends June 5th |