Re: Query Plan choice with timestamps

Поиск
Список
Период
Сортировка
От Richard Huxton
Тема Re: Query Plan choice with timestamps
Дата
Msg-id 489AB3EB.8040903@archonet.com
обсуждение исходный текст
Ответ на Query Plan choice with timestamps  (Giorgio Valoti <giorgio_v@mac.com>)
Ответы Re: Query Plan choice with timestamps  (Giorgio Valoti <giorgio_v@mac.com>)
Список pgsql-performance
Giorgio Valoti wrote:
> Hi, I have a timestamptz field that I want to use with a query, but I
> don’t need the full timestamp resolution, so I’ve created a
> day_trunc(timestamptz) immutable function which I’ll use with the query
> and with a new index:
>
> logs=> create index test_idx on blackbox (day_trunc(ts));
>
> However, the query plan doesn’t use the index:

Does it use it ever? e.g. with
   SELECT * FROM blackbox WHERE day_trunk(ts) = '...'

--
   Richard Huxton
   Archonet Ltd

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

Предыдущее
От: Richard Huxton
Дата:
Сообщение: Re: Plz Heeeelp! performance settings
Следующее
От: dforums
Дата:
Сообщение: Re: Plz Heeeelp! performance settings