Re: _bt_check_unique checks every row in table when doing update??

Поиск
Список
Период
Сортировка
От Bruce Momjian
Тема Re: _bt_check_unique checks every row in table when doing update??
Дата
Msg-id 200209121626.g8CGQl804506@candle.pha.pa.us
обсуждение исходный текст
Ответ на Re: _bt_check_unique checks every row in table when doing update??  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-bugs
Tom Lane wrote:
> > (In my case, I think the call to _bt_check_unique could be
> > avoided altogether since the update isn't changing any of
> > the columns present in the unique key.
>
> It's fairly difficult for the index AM to know that; in general we don't
> have access to the old tuple to check, at the time the index update is
> running.

We do have a TODO item:

* Prevent index uniqueness checks when UPDATE does not modifying column

--
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073

В списке pgsql-bugs по дате отправления:

Предыдущее
От: xayk
Дата:
Сообщение: unsubscribe *
Следующее
От: junk@ns1.tcu-inc.com
Дата:
Сообщение: Re: HELP