Re: Why is this doing a seq scan?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Ingram, Bryan" <BIngram(at)sixtyfootspider(dot)com>
Cc: "'pgsql-sql(at)postgresql(dot)org'" <pgsql-sql(at)postgresql(dot)org>
Subject: Re: Why is this doing a seq scan?
Date: 2000-11-17 20:06:13
Message-ID: 13934.974491573@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Hmm. Have you VACUUM ANALYZED the tables? If so, what do you get from
these queries:

select attname,attdisbursion,s.*
from pg_statistic s, pg_attribute a, pg_class c
where starelid = c.oid and attrelid = c.oid and staattnum = attnum
and relname = 'zips';

select attname,attdisbursion,s.*
from pg_statistic s, pg_attribute a, pg_class c
where starelid = c.oid and attrelid = c.oid and staattnum = attnum
and relname = 'atms';

Also it would be useful to see the full declarations of the tables
and their indexes; I'm wondering what datatype the zip columns are,
for example.

regards, tom lane

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Ingram, Bryan 2000-11-17 20:55:04 RE: Why is this doing a seq scan?
Previous Message Josh Berkus 2000-11-17 19:07:52 Re: Requests for Development