From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgdba <postgresql@inbox.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: Incorrect row estimates in plan?
Date: Wed, 26 Sep 2007 10:45:14 -0400
Message-ID: <20944.1190817914@sss.pgh.pa.us> (raw)
In-Reply-To: <12902068.post@talk.nabble.com>
References: <12902068.post@talk.nabble.com>
pgdba <postgresql@inbox.com> writes:
> -> Bitmap Heap Scan on slog (cost=82.98..6434.62 rows=2870
> width=61) (actual time=50.235..1237.948 rows=83538 loops=1)
> Recheck Cond: ((gid = 10000) AND (rule = ANY
> ('{1,2,8,9,10}'::integer[])) AND (CASE WHEN (rule = ANY
> ('{8,9}'::integer[])) THEN destip ELSE srcip END = '192.168.10.23'::inet))
> -> Bitmap Index Scan on slog_gri_idx (cost=0.00..82.26
> rows=2870 width=0) (actual time=41.306..41.306 rows=83538 loops=1)
> Index Cond: ((gid = 10000) AND (rule = ANY
> ('{1,2,8,9,10}'::integer[])) AND (CASE WHEN (rule = ANY
> ('{8,9}'::integer[])) THEN destip ELSE srcip END = '192.168.10.23'::inet))
[ blink... ] Pray tell, what is the definition of this index?
With such a bizarre scan condition, it's unlikely you'll get any really
accurate row estimate.
regards, tom lane
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 using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: tgl@sss.pgh.pa.us, postgresql@inbox.com
Subject: Re: Incorrect row estimates in plan?
In-Reply-To: <20944.1190817914@sss.pgh.pa.us>
* 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