BUG #2392: Feature request : point_ops

From: "Raphael Jacquot" <raphael(dot)jacquot(at)imag(dot)fr>
To: pgsql-bugs(at)postgresql(dot)org
Subject: BUG #2392: Feature request : point_ops
Date: 2006-04-13 17:02:58
Message-ID: 200604131702.k3DH2wIr051356@wwwmaster.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs


The following bug has been logged online:

Bug reference: 2392
Logged by: Raphael Jacquot
Email address: raphael(dot)jacquot(at)imag(dot)fr
PostgreSQL version: 8.1.3
Operating system: Linux Gentoo 2006.0
Description: Feature request : point_ops
Details:

I have the following table:

CREATE TABLE gps_points (
gpx_id bigint NOT NULL,
capture_time timestamp NOT NULL,
position point NOT NULL,
altitude float,
CONSTRAINT pk__gps_points PRIMARY KEY (gpx_id, capture_time),
CONSTRAINT fk__gps_points__gpx_id FOREIGN KEY (gpx_id) REFERENCES
gpx_files(gpx_id)
);

for which I have the following index:
CREATE INDEX i__gps_points__position ON gps_points USING gist
(box(position,position) box_ops);

it would be nice if point_ops would be available so I could write the index
as:

CREATE INDEX i__gps_points__position ON gps_points USING gist (position
point_ops);

and I could then use :

select * from gps_points where position @ box
'((5.6850162,45.278199),(5.7145111,45.307693))';

instead of the current:

select * from gps_points where box(position,position) @ box
'((5.6850162,45.278199),(5.7145111,45.307693))';

Browse pgsql-bugs by date

  From Date Subject
Next Message Stephan Szabo 2006-04-13 17:09:03 Re: BUG #2390: check constraint
Previous Message Tom Lane 2006-04-13 16:55:41 Re: BUG #2391: "Similar to" pattern matching does not operate as documented