[postgis-users] Problem with functions contains

Miguel de la Fuente mjdelafuente at gmail.com
Thu Oct 6 10:58:17 PDT 2005


Martin: Thank you for your help, sorry I'm feeling a fool.You're right. The
geometry b is completely contained in geometry a, but it no touch the border
line of the geometry b in somewhere.
I did a difference and saw the problem.
 Str, thank you too.


 On 10/5/05, Martin Davis <mbdavis at vividsolutions.com> wrote:
>
> From my testing in JUMP & JTS, it is the case that the table2 geometry (b)
> is completely contained in the table1 geometry (a). I can see the same thing
> as shown in the image, but that's correct - b is the blue geometry, and it
> contains the red geometry (a).
>  To me it looks like PostGIS, JUMP and JTS are all saying the same thing,
> and it matches the geometric situation.
>    *Martin Davis, Senior Technical Architect*
> *Vivid Solutions Inc. www.vividsolutions.com<http://www.vividsolutions.com/>
> *
> *Suite #1A-2328 Government Street Victoria, B.C. V8T 5G5
> Phone: (250) 385 6040 - Local 308 Fax: (250) 385 6046*
>
>  -----Original Message-----
> *From:* postgis-users-bounces at postgis.refractions.net [mailto:
> postgis-users-bounces at postgis.refractions.net] *On Behalf Of *Miguel de la
> Fuente
> *Sent:* October 4, 2005 2:10 PM
> *To:* postgis-users at postgis.refractions.net
> *Subject:* [postgis-users] Problem with functions contains
>
> strk: I' have the following problem, when I use the function contains it
> returns true when the polygons is not totally contains.
> I have applied snaptogrid in my geometry column.
> I did the following :
> update table1 set new_geom=snaptogrid(the_geom,1e-2)
> update table2 set new_geom=snaptogrid(the_geom,1e-2))
> When I use the function contains()
>  select
> b.*
> from table2 b, table1 a
> where contains (b.new_geom,a.new_geom)
> it returns true,but I see visually that b not contains completely a.
>  I don't understand why??
>   I attach the data and a image showing the problem.
>  Thanks.
>
>
> _______________________________________________
> postgis-users mailing list
> postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20051006/2d82536d/attachment.html>


More information about the postgis-users mailing list