Skip site navigation (1) Skip section navigation (2)

Re: FK triggers misused?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: cluster <skrald(at)amossen(dot)dk>
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Re: FK triggers misused?
Date: 2007-04-16 23:49:56
Message-ID: 12205.1176767396@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-performance
cluster <skrald(at)amossen(dot)dk> writes:
>> So the next question is, what pg version is the original poster using?
>> because 8.1.x doesn't report trigger execution times, and 8.2.x would use
>> a single bitmap index scan with an = ANY condition, not a BitmapOr.

> I have tried 8.1.0 and 8.1.3 for this query.

Checking the code, 8.1.x does report trigger times, so AndrewSN is
mistaken on that point.

However, it's also the case that 8.1 does have the suppress-the-trigger
logic for FKs, and it works fine for me in a simple test.  I'm using
8.1 branch tip, but there are no relevant changes since 8.1.0 as far
as I can see in the CVS logs.

What is that non-FK trigger shown in your results?

>    Trigger posts_tsvectorupdate: time=61.659 calls=5

Could it possibly be firing an extra update on the table?

			regards, tom lane

In response to

pgsql-performance by date

Next:From: Tom LaneDate: 2007-04-16 23:55:06
Subject: Re: FK triggers misused?
Previous:From: clusterDate: 2007-04-16 23:12:28
Subject: Re: FK triggers misused?

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group