Re: How to make update rapidly?

Поиск
Список
Период
Сортировка
От Scott Marlowe
Тема Re: How to make update rapidly?
Дата
Msg-id dcc563d10802202323s39ceb8euc0d1c5849c5ce7e0@mail.gmail.com
обсуждение исходный текст
Ответ на Re: How to make update rapidly?  (hewei <heweiweihe@gmail.com>)
Ответы Re: How to make update rapidly?
Список pgsql-general
On Thu, Feb 21, 2008 at 1:07 AM, hewei <heweiweihe@gmail.com> wrote:
> Hi, Scott Marlowe:
>
> You said that " As for processing them in order versus randomly,that's a
> common problem. "
> do you know why? how postgres work in this scenario.

Pretty much the same way any database would.  it's likely that your
data in the table is in some order.  When you update one row, then the
next n rows are read into memory as well.  Updating these is cheaper
because they don't have to be read, just flushed out to the write
ahead log.  If you have very random access on a table much larger than
your shared_buffers or OS cache, then  it's likely that by the time
you get back to a row on page x it's already been flushed out of the
OS  or pg and has to be fetched again.

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

Предыдущее
От: Chris
Дата:
Сообщение: Re: How to view temp tables
Следующее
От: "Scott Marlowe"
Дата:
Сообщение: Re: How to view temp tables