Skip site navigation (1) Skip section navigation (2)

Re: Hi! (and a question)

From: Janko Richter <jankorichter(at)yahoo(dot)de>
To: pgsql-novice(at)postgresql(dot)org
Subject: Re: Hi! (and a question)
Date: 2004-05-07 09:18:14
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-novice
David Cruz wrote:
> Hello everyone!
> My name is David Cruz, and I'm from Bogota, Colombia.
> I'm Beggining with PostgreSQL, so I've been doing just
> a few simple things.
> I have a problem, in my database there is a table
> which has some geometric data types: (point and
> polygon) and a need some operator or function that let
> me know if the point is inside the polygon or not.
> Something like the ~ in the point inside a circle, but
> this one is inside a polygon.
> thanks a lot!

What PGSQL version do you are using? I found the point ~ polygon
operator in version 7.4.

  SELECT '0.5,0.5'::point @ '(-1,0),(-1,-1),(1,-1),(1,1)'::polygon;
  SELECT  '(-1,0),(-1,-1),(1,-1),(1,1)'::polygon ~ '0.5,0.5'::point;

Regards, Janko Richter

In response to


pgsql-novice by date

Next:From: Carlos BarrosoDate: 2004-05-07 15:14:06
Subject: Problem inserting more than 80 registers!?
Previous:From: David CruzDate: 2004-05-07 04:56:37
Subject: Hi! (and a question)

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group