Planner ignoring to use INDEX SCAN

Поиск
Список
Период
Сортировка
От Ashish Karalkar
Тема Planner ignoring to use INDEX SCAN
Дата
Msg-id 835235.23869.qm@web94306.mail.in2.yahoo.com
обсуждение исходный текст
Ответы Re: Planner ignoring to use INDEX SCAN  (Richard Huxton <dev@archonet.com>)
Список 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 по дате отправления:

Предыдущее
От: Ow Mun Heng
Дата:
Сообщение: Re: HouseKeeping and vacuum Questions
Следующее
От: Richard Huxton
Дата:
Сообщение: Re: Planner ignoring to use INDEX SCAN