Re: Incorrect Sort Using Index Scan
| От | Tom Lane |
|---|---|
| Тема | Re: Incorrect Sort Using Index Scan |
| Дата | |
| Msg-id | 4924.1347945472@sss.pgh.pa.us обсуждение |
| Ответ на | Incorrect Sort Using Index Scan ("McGehee, Robert" <Robert.McGehee@geodecapital.com>) |
| Список | pgsql-bugs |
"McGehee, Robert" <Robert.McGehee@geodecapital.com> writes:
> I have recently upgraded to PostgreSQL 9.2.0 and one of my queries is now giving incorrectly sorted results due, I
believe,to the new index-only scan in 9.2.0. The below table is a table of currency FX rates by date.
Hmm, no it's not about index-only scans (your query isn't even using
one). I think this got broken in my commit
9e8da0f75731aaa7605cf4656c21ea09e84d2eb1, which turned =ANY into a
native index qualification type for btree. I thought that the output
could still be considered sorted by the index's sort order, but this
example proves that that's not so. Need to think a bit more carefully
about that --- maybe we can only assume sorted output when the =ANY qual
is for the first index column. Or maybe we can't assume it at all.
regards, tom lane
В списке pgsql-bugs по дате отправления: