X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 6CDAC329FA7 for ; Wed, 29 Sep 2004 03:42:36 +0100 (BST) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 55831-01 for ; Wed, 29 Sep 2004 02:42:09 +0000 (GMT) Received: from mproxy.gmail.com (rproxy.gmail.com [64.233.170.201]) by svr1.postgresql.org (Postfix) with ESMTP id 1A64432A10A for ; Wed, 29 Sep 2004 03:41:55 +0100 (BST) Received: by mproxy.gmail.com with SMTP id 73so2851314rnk for ; Tue, 28 Sep 2004 19:41:50 -0700 (PDT) Received: by 10.38.208.53 with SMTP id f53mr1501805rng; Tue, 28 Sep 2004 19:41:50 -0700 (PDT) Received: by 10.38.165.21 with HTTP; Tue, 28 Sep 2004 19:41:50 -0700 (PDT) Message-ID: Date: Tue, 28 Sep 2004 21:41:50 -0500 From: Kevin Barnard Reply-To: Kevin Barnard To: Robert Creager Subject: Re: This query is still running after 10 hours... Cc: pgsql-performance@postgresql.org In-Reply-To: <20040928202140.4ea9d090@thunder.mshome.net> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit References: <20040928081957.7a317a95@thunder.mshome.net> <20040928202140.4ea9d090@thunder.mshome.net> X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200409/318 X-Sequence-Number: 8446 On Tue, 28 Sep 2004 20:21:40 -0600, Robert Creager wrote: > > The trigger keeps another table (catalog) up to date with the information from the obs_v and obs_i tables. There are no direct insert/update/delete's on the catalog table, only though the trigger. > It's possible that the update to catalog is what is really taking a long time. You might wish to try and explain that query just to make sure. You might also wish to disable to trigger just to rule it out. Does catalog have any triggers on it? Does it have any foreign keys? I've shot myself in the foot on this before which is the only reason I ask about it.