Re: ARRAYs and INDEXes ...

Поиск
Список
Период
Сортировка
От Greg Stark
Тема Re: ARRAYs and INDEXes ...
Дата
Msg-id 877jemvsfj.fsf@stark.xeocode.com
обсуждение исходный текст
Ответ на ARRAYs and INDEXes ...  ("Marc G. Fournier" <scrappy@postgresql.org>)
Список pgsql-sql
"Marc G. Fournier" <scrappy@postgresql.org> writes:

> SELECT * FROM customers WHERE monthly_balance[6] = 0.00;

This, like the other poster said, can be accomplished with a set of simple
expression indexes.

> As an example ... or
> 
> SELECT * FROM customers WHERE 0.00 = any (monthly_balance);

This would require a GiST index. Look at the intarray contrib module. I don't
think there's any equivalent for other data types. You might have to store
these values as fixed precision numbers and divide or multiple by 100 to
convert.

-- 
greg



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

Предыдущее
От: The One
Дата:
Сообщение: What libraries need to be included in C program for encrypt and decrypt functions?
Следующее
От: "Owen Jacobson"
Дата:
Сообщение: Re: What libraries need to be included in C program for encrypt and decrypt functions?