Planner ignoring to use INDEX SCAN - Mailing list pgsql-general

From Ashish Karalkar
Subject Planner ignoring to use INDEX SCAN
Date
Msg-id 835235.23869.qm@web94306.mail.in2.yahoo.com
Whole thread Raw
Responses Re: Planner ignoring to use INDEX SCAN
List pgsql-general
Hello All,

I have two table:

master_table:
pk_id bigint primary key,
name text


child_table :
chk_id bigint,
pk_id bigint
mob varchar(15)

foreign key pk_id to master_table
index on pk_id of child

 query which was taking seconds on the join of these two table suddenly started taking 20/25 min

child table has @ 100M rows

The only deifference was I dropped the foreign key pointing to parent pk_id after this the planner is ignoring to use index scan on child table and doing seq scan.

Is it because  I dropped foreign key?

Thanks in advance

With regards
Ashish...














Now you can chat without downloading messenger. Click here to know how.

pgsql-general by date:

Previous
From: Ow Mun Heng
Date:
Subject: Re: HouseKeeping and vacuum Questions
Next
From: Richard Huxton
Date:
Subject: Re: Planner ignoring to use INDEX SCAN