pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Shridhar Daithankar <shridhar_daithankar@persistent.co.in>
To: pgsql-performance@postgresql.org
Subject: Re: index / sequential scan problem
Date: Thu, 17 Jul 2003 14:47:46 +0530
Message-ID: <3F16B712.19311.58D7530@localhost> (raw)
In-Reply-To: <5.1.0.14.0.20030717105203.03d2b5c0@195.145.148.245>

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




view thread (19+ messages)  latest in thread

Message-ID: <3F16B712.19311.58D7530@localhost>
Permalink:  ../3F16B712.19311.58D7530@localhost/
Also on:    postgresql.org/message-id/3F16B712.19311.58D7530@localhost

 · 

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-performance@postgresql.org
  Cc: shridhar_daithankar@persistent.co.in
  Subject: Re: index / sequential scan problem
  In-Reply-To: <3F16B712.19311.58D7530@localhost>
  References: <5.1.0.14.0.20030717105203.03d2b5c0@195.145.148.245> <3F16B712.19311.58D7530@localhost>

* 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