Re: BUG #18825: Row value equality predicates do not use indices
От | Tom Lane |
---|---|
Тема | Re: BUG #18825: Row value equality predicates do not use indices |
Дата | |
Msg-id | 1678855.1740530682@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | BUG #18825: Row value equality predicates do not use indices (PG Bug reporting form <noreply@postgresql.org>) |
Ответы |
Re: BUG #18825: Row value equality predicates do not use indices
|
Список | pgsql-bugs |
PG Bug reporting form <noreply@postgresql.org> writes: > DELETE FROM foo USING (SELECT dels FROM dels) AS dels > WHERE foo = dels; -- <--- does not use indices on either table [ shrug... ] Works for me given the full-row indexes, although I do have to force enable_seqscan off or reduce random_page_cost a lot, because otherwise the planner thinks a seqscan-and-sort is cheaper. I strongly suspect it's right, because full-row indexes are going to be bigger than the table proper. The mere fact that a plan uses indexes does not automatically make it better than one that doesn't. Anyway, AFAICS your gripe has nothing to do with "can the planner use these indexes", and everything to do with its cost estimates about the value of doing it that way. regards, tom lane
В списке pgsql-bugs по дате отправления: