| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | Oleg Bartunov <oleg(at)sai(dot)msu(dot)su> |
| Cc: | Teodor Sigaev <teodor(at)stack(dot)net>, Bill Studenmund <wrstuden(at)netbsd(dot)org>, pgsql-hackers(at)postgresql(dot)org |
| Subject: | Re: Proposed new create command, CREATE OPERATOR CLASS |
| Date: | 2001-10-29 17:18:55 |
| Message-ID: | 10397.1004375935@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
Oleg Bartunov <oleg(at)sai(dot)msu(dot)su> writes:
> this is interesting question - do we really need commutator to get
> postgres to use index. This is the only reason we created ~~ operator.
AFAIR there is not a requirement to have a commutator link. However
the indexable operation has to be framed as "indexedvar OP constant".
If the natural way to write it is as "constant OP indexedvar" then
you won't get an indexscan unless it can be commuted to the other way.
The same issue arises if you think that the operator might be useful
in joins.
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | mlw | 2001-10-29 17:30:15 | Re: External Database Connection |
| Previous Message | Tom Lane | 2001-10-29 17:10:55 | Re: [patch] helps fe-connect.c handle -EINTR more gracefully |