Re: Suggestion for optimization

Поиск
Список
Период
Сортировка
От Doug McNaught
Тема Re: Suggestion for optimization
Дата
Msg-id m3k7rlzzs4.fsf@varsoon.wireboard.com
обсуждение исходный текст
Ответ на Re: Suggestion for optimization  ("Dann Corbit" <DCorbit@connx.com>)
Список pgsql-hackers
"Dann Corbit" <DCorbit@connx.com> writes:

> How would this work with MVCC?
> >>
> Whenever a commit occurs, the pending inserts are totaled into the sum
> and the pending deletes are subtracted.  It can be a list in memory or
> whatever.  Maybe you are referring to the old (expired) rows begin
> stored until vacuum?  Perhaps I really don't understand your question or
> the issues involved.  Why does MVCC complicate issues?
> <<

Because the row count depends on what transactions have committed when
yours starts.  Also, you will see the count(*) reflecting INSERTs in
your transaction, but others won't until you commit.  So there is no
well-defined concept of cardinality under MVCC--it depends on which
rows are visible to which transactions.

-Doug
-- 
Doug McNaught       Wireboard Industries      http://www.wireboard.com/
     Custom software development, systems and network consulting.     Java PostgreSQL Enhydra Python Zope Perl Apache
LinuxBSD...
 


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Doug McNaught
Дата:
Сообщение: Re: Suggestion for optimization
Следующее
От: "Dann Corbit"
Дата:
Сообщение: Re: Suggestion for optimization