| От | Mark Lewis |
|---|---|
| Тема | Re: count * performance issue |
| Дата | |
| Msg-id | 1204820047.9048.902.camel@archimedes обсуждение исходный текст |
| Ответ на | Re: count * performance issue (Craig James <craig_james@emolecules.com>) |
| Список | pgsql-performance |
On Thu, 2008-03-06 at 07:28 -0800, Craig James wrote: ... > My question is: What do the other databases do that Postgres can't do, and why not? > > Count() on Oracle and MySQL is almost instantaneous, even for very large tables. So why can't Postgres do what they do? ... I can vouch that Oracle can still take linear time to perform a count(*), at least in some cases. I have also seen count(*) fast in some cases too... my understanding is that they maintain a list of "interested transactions" on a per-relation basis. Perhaps they do an optimization based on the index size if there are no pending DML transactions? -- Mark
В списке pgsql-performance по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера