On Tue, Nov 9, 2010 at 2:48 PM, Andy Colson <andy@xxxxxxxxxxxxxxx> wrote: > On 11/9/2010 3:26 PM, bricklen wrote: > >> Â Â Â Â Â-> Â Seq Scan on conversionrejected cr Â(cost=0.00..191921.82 >> rows=11012682 width=31) (actual time=0.003..1515.816 rows=11012682 >> loops=72) >> ÂTotal runtime: 292668.992 ms >> > > Looks like the table stats are ok. ÂBut its doing a sequential scan. Are you > missing an index? > > Also: > > http://explain.depesz.com/ > > is magic. > > -Andy > The PK is on the conversionrejected table in all three databases I tested (I also tested our Greenplum datawarehouse). The "idconversion" attribute is a bigint in both tables, so it's not a type mismatch. \d conversionrejected Table "public.conversionrejected" Column | Type | Modifiers ----------------+--------+----------- idconversion | bigint | not null rejectedreason | text | not null Indexes: "conversionrejected_pk" PRIMARY KEY, btree (idconversion) Yeah, that explain visualizer from depesz is a handy tool, I use frequently. -- Sent via pgsql-performance mailing list (pgsql-performance@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-performance