X-Original-To: pgsql-performance-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [64.117.224.192]) by svr1.postgresql.org (Postfix) with ESMTP id 09341CC866 for ; Thu, 17 Jul 2003 09:15:43 +0000 (GMT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (svr4.postgresql.org [64.117.224.192]) (amavisd-new, port 10024) with ESMTP id 66026-04 for ; Thu, 17 Jul 2003 09:16:05 +0000 (GMT) Received: from smtp.pspl.co.in (unknown [202.54.11.65]) by svr1.postgresql.org (Postfix) with ESMTP id ACC44CAE14 for ; Thu, 17 Jul 2003 06:15:36 -0300 (ADT) Received: (from root@localhost) by smtp.pspl.co.in (8.12.9/8.12.9) id h6H9K29i009393 for ; Thu, 17 Jul 2003 14:50:02 +0530 Received: from daithan (daithan.intranet.pspl.co.in [192.168.7.161]) (authenticated bits=0) by smtp.pspl.co.in (8.12.9/8.12.9) with ESMTP id h6H9K1uf009380 for ; Thu, 17 Jul 2003 14:50:02 +0530 From: "Shridhar Daithankar" To: pgsql-performance@postgresql.org Date: Thu, 17 Jul 2003 14:47:46 +0530 MIME-Version: 1.0 Subject: Re: index / sequential scan problem Reply-To: shridhar_daithankar@persistent.co.in Message-ID: <3F16B712.19311.58D7530@localhost> In-reply-to: <5.1.0.14.0.20030717105203.03d2b5c0@195.145.148.245> X-mailer: Pegasus Mail for Windows (v4.12a) Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7BIT Content-description: Mail message body X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200307/244 X-Sequence-Number: 2537 On 17 Jul 2003 at 11:01, Fabian Kreitner wrote: > psql (PostgreSQL) 7.2.2 > > perg_1097=# VACUUM ANALYZE ; > VACUUM > perg_1097=# EXPLAIN ANALYZE select notiz_id, obj_id, obj_typ > perg_1097-# from notiz_objekt a > perg_1097-# where not exists > perg_1097-# ( > perg_1097(# select 1 > perg_1097(# from notiz_gelesen b > perg_1097(# where ma_id = 2001 > perg_1097(# and ma_pid = 1097 > perg_1097(# and a.notiz_id = b.notiz_id > perg_1097(# ) > perg_1097-# ; For 31K records, seq. scan does not sound like a bad plan to me but anyway.. How about where ma_id = 2001::integer and ma_pid = 1097::integer in above query? Bye Shridhar -- No one can guarantee the actions of another. -- Spock, "Day of the Dove", stardate unknown