| От | Jack Orenstein |
|---|---|
| Тема | Re: Postgres optimizer choosing wrong index |
| Дата | |
| Msg-id | 49072350.3040505@hds.com обсуждение исходный текст |
| Ответ на | Re: Postgres optimizer choosing wrong index (Tom Lane <tgl@sss.pgh.pa.us>) |
| Список | pgsql-general |
Tom Lane wrote: > Jack Orenstein <jack.orenstein@hds.com> writes: >> EXPLAIN says that the correct index is being used -- it didn't used >> to. However, pg_stat* says otherwise. In my test, I have exactly one >> dh value. Running EXPLAIN with this value produces a plan using idx_dh >> (the correct index), but pg_stats says that idx_dn is being used (see >> psql session below). > > Yeah, if you are using cached plans (via PREPARE or plpgsql functions) > then the plan stays the same for the life of the session ... pre 8.3 > that is. Thank you. One of the great things about postgres is being able to understand things all the way down with the patient help of the actual developers. Jack
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера