Re: A plan returned by explain doesn't make sense to me

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: A plan returned by explain doesn't make sense to me
Дата
Msg-id 24465.1018022022@sss.pgh.pa.us
обсуждение исходный текст
Ответ на A plan returned by explain doesn't make sense to me  ("Nick Fankhauser" <nickf@ontko.com>)
Ответы Re: A plan returned by explain doesn't make sense to me  ("Nick Fankhauser" <nickf@ontko.com>)
Список pgsql-admin
"Nick Fankhauser" <nickf@ontko.com> writes:
> The part that looks wrong to me is that on the last line of the explain, it
> is using the index "actor_case_assignment_both" (the index on
> actor_id,case_id) even though actor_id is never referenced in this query and
> and index on case_id alone is available.

That seems strange to me also, particularly if the index column ordering
is indeed actor_id,case_id and not the other way round --- without some
constraint on actor_id it shouldn't be *possible* to use such an index.
Could you send me a schema dump (pg_dump -s) for experimentation?
Also, which PG version are you using?

            regards, tom lane

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

Предыдущее
От: "Nick Fankhauser"
Дата:
Сообщение: error in my last post
Следующее
От: Bruce Young
Дата:
Сообщение: Data Files