Re: select count(*) from anIntColumn where int_value =

Поиск
Список
Период
Сортировка
От Christopher Kings-Lynne
Тема Re: select count(*) from anIntColumn where int_value =
Дата
Msg-id 402ADE8D.1090802@familyhealth.com.au
обсуждение исходный текст
Ответ на Re: select count(*) from anIntColumn where int_value = 0;  ("scott.marlowe" <scott.marlowe@ihs.com>)
Список pgsql-performance
>>>Is your int_value data type int4? If not then use "... from
>>>job_property
>>>where int_value = '0'"
>>>Indexes are used only if datatypes matches.
>>>
>>
>>tried those variations already. Strange enough, after dropping and
>>recreating the index everything worked fine.
>
>
> Has that table been updated a lot in its life?  If so, it may have had a
> problem with index bloat...

Try creating a partial index: create index blah on tablw where int_value=0;

Chris


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

Предыдущее
От: Mark Kirkwood
Дата:
Сообщение: Re: slow database
Следующее
От: Leon Out
Дата:
Сообщение: Disappointing performance in db migrated from MS SQL Server