Re: force index problem in 8.4.1 - Mailing list pgsql-hackers

From Oleg Bartunov
Subject Re: force index problem in 8.4.1
Date
Msg-id Pine.LNX.4.64.0911260953060.6801@sn.sai.msu.ru
Whole thread Raw
In response to Re: force index problem in 8.4.1  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: force index problem in 8.4.1
List pgsql-hackers
On Wed, 25 Nov 2009, Tom Lane wrote:

> Oleg Bartunov <oleg@sai.msu.su> writes:
>> I tried to force query to use index by specifying high execution cost, but
>> without success, even seqscan cost doesn't changed. This is 8.4.1
>
> I think you altered the wrong function.  The function underlying
> point <@ box is on_pb() not pt_contained_box ... in fact, I don't
> even see a function named that.

sorry, I forgot to say, that I created operator

CREATE OR REPLACE FUNCTION pt_contained_box(point, box)        RETURNS bool        AS 'MODULE_PATHNAME'        LANGUAGE
'C'       IMMUTABLE RETURNS NULL ON NULL INPUT;
 

CREATE OPERATOR <@ (        LEFTARG = point,        RIGHTARG = box,        PROCEDURE = pt_contained_box,
COMMUTATOR= '@>',        RESTRICT = contsel,        JOIN = contjoinsel
 
);

    Regards,        Oleg
_____________________________________________________________
Oleg Bartunov, Research Scientist, Head of AstroNet (www.astronet.ru),
Sternberg Astronomical Institute, Moscow University, Russia
Internet: oleg@sai.msu.su, http://www.sai.msu.su/~megera/
phone: +007(495)939-16-83, +007(495)939-23-83


pgsql-hackers by date:

Previous
From: Heikki Linnakangas
Date:
Subject: Re: Hot Standby and cancelling idle queries
Next
From: Fujii Masao
Date:
Subject: Backup history file should be replicated in Streaming Replication?