Re: [SQL] ARRAYs and INDEXes ...

2005-08-16 Thread Greg Stark
"Marc G. Fournier" <[EMAIL PROTECTED]> 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 w

Re: [SQL] ARRAYs and INDEXes ...

2005-08-15 Thread Michael Fuhr
On Tue, Aug 16, 2005 at 01:54:13AM -0300, Marc G. Fournier wrote: > > CREATE TABLE customers ( > customer_id SERIAL, > monthly_balance DECIMAL(7,2)[12] > ); > > Is it possible to create an INDEX on customers.monthly_balance such that I > could do something like: > > SELECT * FROM customers W

[SQL] ARRAYs and INDEXes ...

2005-08-15 Thread Marc G. Fournier
Can't seem to find anything concerning this in the docs, and I don't think it is something that can be done, but figure I'll double check before I write it off completely ... If I create a table: CREATE TABLE customers ( customer_id SERIAL, monthly_balance DECIMAL(7,2)[12] ); Is it poss