Thread: Bug: Constraint Trigger - created with pgadmin - is not visible and missing in SQL Pane / Create Script

<div class="WordSection1"><p class="MsoNormal"><span lang="EN-US">I created a new constraint trigger via pgadmin user
interface:</span><pclass="MsoNormal"><span lang="EN-US"> </span><p class="MsoNormal"><span lang="EN-US">Right click on
table-> New Object -> New Trigger</span><p class="MsoNormal"><span lang="EN-US">Checked “Constraint Trigger” (on
DefinitionTab)</span><p class="MsoNormal"><span lang="EN-US"> </span><p class="MsoNormal"><span lang="EN-US">This
Triggeris not visible in pgadmin.</span><p class="MsoNormal"><span lang="EN-US"> </span><p class="MsoNormal"><span
lang="EN-US">OnSQL pane and Create Script this trigger is missing.</span><p class="MsoNormal"><span
lang="EN-US"> </span><pclass="MsoNormal"><span lang="EN-US">Trigger works / Trigger Function is fired.</span><p
class="MsoNormal"><spanlang="EN-US"> </span><p class="MsoNormal"><span lang="EN-US">When I check this with phppgadmin I
cansee the trigger. Export in phppgadmin includes the trigger. </span><p class="MsoNormal"><span
lang="EN-US"> </span><pclass="MsoNormal"><span lang="EN-US">SQL Statement for the trigger (from phppgadmin Export)
is</span><pclass="MsoNormal"><span lang="EN-US"> </span><pre><span lang="EN-US" style="color:black">--</span></pre>
<pre><spanlang="EN-US" style="color:black">-- Name: … ; Type: TRIGGER; Schema:  … ; Owner: …</span></pre> <pre><span
style="color:black">--</span></pre><pclass="MsoNormal"><span lang="EN-US" style="font-size:10.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE">CREATECONSTRAINT TRIGGER <trigger-name> AFTER INSERT ON
<table-name>NOT DEFERRABLE INITIALLY IMMEDIATE FOR EACH ROW EXECUTE PROCEDURE <trigger-function>;</span><p
class="MsoNormal"><spanlang="EN-US"> </span><p class="MsoNormal"><span lang="EN-US">From my understanding this trigger
shouldbe listed in Table Constraints and should be included in Create Script.</span><p class="MsoNormal"><span
lang="EN-US"> </span><pclass="MsoNormal"><span lang="EN-US">PostgreSQL 9.1.3 on x86_64-pc-linux-gnu, compiled by
gcc-4.6.real(Ubuntu/Linaro 4.6.1-9ubuntu3) 4.6.1, 64-bit (installed via Ubuntu package 9.1.3-0ubuntu0.11.10)</span><p
class="MsoNormal"><spanlang="EN-US">pgAdmin 1.14.2 (Feb 24 2012, rev: REL-1_14_2)</span><p class="MsoNormal"><span
lang="EN-US"> </span><pclass="MsoNormal"><span lang="EN-US">Regards, Michael</span><p class="MsoNormal"><span
lang="EN-US"> </span><pclass="MsoNormal"><span lang="EN-US"> </span></div> 
On Mon, 2012-04-30 at 13:02 +0000, Michael Brux wrote:
> I created a new constraint trigger via pgadmin user interface:
> 
> Right click on table -> New Object -> New Trigger
> Checked "Constraint Trigger" (on Definition Tab)
> 
> This Trigger is not visible in pgadmin.
> 
> On SQL pane and Create Script this trigger is missing.
> 

Yes, you're right. The SQL statement is now fixed. I just pushed the
patch.

Thanks for your report.


-- 
Guillaume
http://blog.guillaume.lelarge.info
http://www.dalibo.com