Re: [SQL] Indices and user defined operators

2005-06-09 Thread Richard Huxton
Tom Lane wrote: I wrote: Dmitri Bichko [EMAIL PROTECTED] writes: So, is there any way to make these operators use an index defined as above? If you've set things up so that the operators are defined by inline-able SQL functions, I'd sort of expect it to fall out for free ... Now *that*

[SQL] Indices and user defined operators

2005-06-08 Thread Dmitri Bichko
Being lazy, I've created a set of case incensitive text comparison operators: =*, *, *, and !=*; the function for each just does an UPPER() on both arguments and then uses the corresponding builtin operator. What would make these REALLY useful, is if when running something like: SELECT * FROM

Re: [SQL] Indices and user defined operators

2005-06-08 Thread Tom Lane
Dmitri Bichko [EMAIL PROTECTED] writes: So, is there any way to make these operators use an index defined as above? If you've set things up so that the operators are defined by inline-able SQL functions, I'd sort of expect it to fall out for free ... regards, tom lane

Re: [SQL] Indices and user defined operators

2005-06-08 Thread Tom Lane
I wrote: Dmitri Bichko [EMAIL PROTECTED] writes: So, is there any way to make these operators use an index defined as above? If you've set things up so that the operators are defined by inline-able SQL functions, I'd sort of expect it to fall out for free ... Here's a quick