Re: "Unlogged indexes"

Поиск
Список
Период
Сортировка
От Thom Brown
Тема Re: "Unlogged indexes"
Дата
Msg-id CAA-aLv7NODw3-D6=ONq-k4EAVqd1TMAciXXL+O7brM2XfLVPmA@mail.gmail.com
обсуждение исходный текст
Ответ на "Unlogged indexes"  (Yang Zhang <yanghatespam@gmail.com>)
Ответы Re: "Unlogged indexes"  (Yang Zhang <yanghatespam@gmail.com>)
Список pgsql-general
On 3 May 2013 21:06, Yang Zhang <yanghatespam@gmail.com> wrote:
> Guessing the answer's no, but is there any way to construct indexes
> such that I can safely put them on (faster) volatile storage? (Just to
> be clear, I'm asking about indexes for *logged* tables.)

Yes:

CREATE INDEX ... TABLESPACE tablespacename;
ALTER INDEX ... SET TABLESPACE tablespacename;

Although there's a disparity between your email subject and main text.
 Indexes for logged tables are always logged.  If you want an unlogged
index you can only create it for an unlogged table.

And putting indexes on a separate tablespace is probably not as
advantageous as you're thinking.  Might be worth testing.

--
Thom


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

Предыдущее
От: Yang Zhang
Дата:
Сообщение: "Unlogged indexes"
Следующее
От: Yang Zhang
Дата:
Сообщение: Re: "Unlogged indexes"