Re: Poor performance of delete by primary key

From: "Jim C(dot) Nasby" <jnasby(at)pervasive(dot)com>
To: Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Brian Choate <brianc(at)nimblefish(dot)com>, pgsql-performance(at)postgresql(dot)org
Subject: Re: Poor performance of delete by primary key
Date: 2005-09-07 21:38:34
Message-ID: 20050907213834.GB83885@pervasive.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

On Wed, Sep 07, 2005 at 11:07:04AM +0800, Christopher Kings-Lynne wrote:
> >Unfortunately there's no very simple way to determine which FK is the
> >problem. (In 8.1 it'll be possible to do that with EXPLAIN ANALYZE,
> >but in existing releases EXPLAIN doesn't break out the time spent in
> >each trigger ...) You have to just eyeball the schema :-(.
>
> phpPgAdmin has a handy info feature where you can see all tables that
> refer to the current one. You can always go and steal that query to
> find them...

You can also use pg_user_foreighn_key* from
http://pgfoundry.org/projects/newsysviews/.
--
Jim C. Nasby, Sr. Engineering Consultant jnasby(at)pervasive(dot)com
Pervasive Software http://pervasive.com work: 512-231-6117
vcard: http://jim.nasby.net/pervasive.vcf cell: 512-569-9461

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message wisan watcharinporn 2005-09-09 05:54:15 please comment on cpu 32 bit or 64 bit
Previous Message Alex Hayward 2005-09-07 18:40:57 Re: Query take 101 minutes, help, please