| От | Simon Riggs |
|---|---|
| Тема | Re: Searching for the cause of a bad plan |
| Дата | |
| Msg-id | 1190396352.4202.109.camel@ebony.site обсуждение |
| Ответ на | Re: Searching for the cause of a bad plan (Tom Lane <tgl@sss.pgh.pa.us>) |
| Ответы |
Re: Searching for the cause of a bad plan
|
| Список | pgsql-performance |
On Fri, 2007-09-21 at 12:08 -0400, Tom Lane wrote: > Csaba Nagy <nagy@ecircle-ag.com> writes: > > Looking at Plan 2, it looks like the "limit" step is estimating wrongly > > it's cost. > > The reason you get a bad plan is that this rowcount estimate is so far > off: That's true, but its not relevant, since the query would still be fast even if that estimate was exactly right. With LIMIT 10, it wouldn't matter how many rows were there as long as there were more than 10. The true execution cost is limited, the cost model is not. -- Simon Riggs 2ndQuadrant http://www.2ndQuadrant.com
В списке pgsql-performance по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера