Re: [GENERAL] Question slow query

Поиск
Список
Период
Сортировка
От John R Pierce
Тема Re: [GENERAL] Question slow query
Дата
Msg-id 9e5f31e6-a295-e5ed-60b2-6162aae8ef2a@hogranch.com
обсуждение исходный текст
Ответ на Re: [GENERAL] Question slow query  (Patrick B <patrickbakerbr@gmail.com>)
Ответы Re: [GENERAL] Question slow query  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
On 1/16/2017 11:27 AM, Patrick B wrote:

Sorry about that.. just wanted to understand how to index a timestamp column. I was able to do this way:

CREATE INDEX CONCURRENTLY ON note (timezone('Etc/UTC'::text, d_date));


why did you prefix your index with timezone('etc/UTC'::text ???   that doesn't make sense to me at all.   is timezone() some function you've defined?  I'm not aware of any built in function by that name.


create index concurrently on table(columnname);   should index a timestamp column, the same as any other column.


you still haven't told us what query it is thats taking 25 seconds.


-- 
john r pierce, recycling bits in santa cruz

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

Предыдущее
От: Venkata B Nagothi
Дата:
Сообщение: Re: [GENERAL] Question slow query
Следующее
От: Adam Dratwiński
Дата:
Сообщение: [GENERAL] Reading VARTAT EXTERNAL ONDISK value from logical replication decoder