Received: from localhost (unknown [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id E65D12E0213 for ; Tue, 11 Dec 2007 00:25:03 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 01045-07 for ; Tue, 11 Dec 2007 00:25:00 -0400 (AST) Received: from vms042pub.verizon.net (vms042pub.verizon.net [206.46.252.42]) by postgresql.org (Postfix) with ESMTP id 0B2AF2E00C4 for ; Tue, 11 Dec 2007 00:25:01 -0400 (AST) Received: from [192.168.2.102] ([71.100.89.137]) by vms042.mailsrvcs.net (Sun Java System Messaging Server 6.2-6.01 (built Apr 3 2006)) with ESMTPA id <0JSV00J93AXODHVA@vms042.mailsrvcs.net> for pgsql-sql@postgresql.org; Mon, 10 Dec 2007 22:25:00 -0600 (CST) Date: Mon, 10 Dec 2007 23:24:59 -0500 From: Gerry Reno Subject: Re: join on three tables is slow In-reply-to: <475CC478.7010102@Sheeky.Biz> To: pgsql-sql@postgresql.org Message-id: <475E111B.6060203@verizon.net> MIME-version: 1.0 Content-type: text/plain; charset=ISO-8859-1; format=flowed Content-transfer-encoding: 7bit References: <475C96EA.6090002@verizon.net> <475CC478.7010102@Sheeky.Biz> User-Agent: Thunderbird 1.5.0.12 (X11/20070530) X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.042 tagged_above=0 required=5 tests=AWL=1.153, BAYES_05=-1.11 X-Spam-Level: X-Archive-Number: 200712/41 X-Sequence-Number: 29733 Ok, I've been playing around with this SQL some more and I found that if I remove this: e.active = '1' from the query that the query now completes in 5 seconds. Nothing else has anywhere near the impact of this boolean condition. So what is it about this boolean field that is causing so much delay? Gerry