pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Jim C. Nasby <jnasby@pervasive.com>
To: Sriram Dandapani <sdandapani@counterpane.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: dropping partitioned table waits forever
Date: Tue, 15 Aug 2006 16:32:03 -0500
Message-ID: <20060815213203.GN21363@pervasive.com> (raw)
In-Reply-To: <6992E470F12A444BB787B5C937B9D4DF0574F731@ca-mail1.cis.local>
References: <6992E470F12A444BB787B5C937B9D4DF0574F731@ca-mail1.cis.local>

On Mon, Aug 14, 2006 at 03:32:10PM -0700, Sriram Dandapani wrote:
> Hi
> 
>  
> 
> I have a table partitioned on a daily basis. Data is constantly inserted
> in this table. When I attempt to drop a partition that is not used(i.e
> previous day's), the drop table waits for a loooong time.This is
> probably due to the fact that the old partitioned table is being
> referenced in a query plan(the insert into the parent table uses
> triggers).
> 
> How can I prevent the locking out of the drop table? I tried truncate
> table but it is worse. It locks out the inserts in the parent table and
> then it waits.(hence causing a deadlock)

What about dropping/changing the trigger?
-- 
Jim C. Nasby, Sr. Engineering Consultant      jnasby@pervasive.com
Pervasive Software      http://pervasive.com    work: 512-231-6117
vcard: http://jim.nasby.net/pervasive.vcf       cell: 512-569-9461



view thread (9+ messages)  latest in thread

Message-ID: <20060815213203.GN21363@pervasive.com>
Permalink:  ../20060815213203.GN21363@pervasive.com/
Also on:    postgresql.org/message-id/20060815213203.GN21363@pervasive.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: jnasby@pervasive.com, sdandapani@counterpane.com
  Subject: Re: dropping partitioned table waits forever
  In-Reply-To: <20060815213203.GN21363@pervasive.com>
  References: <6992E470F12A444BB787B5C937B9D4DF0574F731@ca-mail1.cis.local> <20060815213203.GN21363@pervasive.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox