| От | Tom Lane |
|---|---|
| Тема | Re: Seqscan in MAX(index_column) |
| Дата | |
| Msg-id | 25643.1062731297@sss.pgh.pa.us обсуждение |
| Ответ на | Re: Seqscan in MAX(index_column) (Bruce Momjian <pgman@candle.pha.pa.us>) |
| Ответы |
Re: Seqscan in MAX(index_column)
|
| Список | pgsql-hackers |
Bruce Momjian <pgman@candle.pha.pa.us> writes:
> Neil Conway wrote:
>> In general, I don't think this is worth doing.
> It is possible it isn't worth doing. Can the INSERT/DELETE
> incrementing/decrementing the cached count work reliabily?
I don't even see how the notion of a single cached value makes
theoretical sense, when in principle every transaction may have
a different idea of the correct answer.
You could doubtless maintain a fairly good approximate total this
way, and that would be highly useful for some applications ...
but it isn't COUNT(*).
regards, tom lane
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера