Ticket #832 (closed defect: invalid)
Wrong line from ST_Difference
| Reported by: | aperi2007 | Owned by: | pramsey |
|---|---|---|---|
| Priority: | medium | Milestone: | PostGIS 2.0.0 |
| Component: | postgis | Version: | trunk |
| Keywords: | Cc: |
Description
I notice this strange results:
If I try this sql:
SELECT ST_AsText(
ST_Difference(
ST_GeomFromText('LINESTRING(50 49.9999999999999, 50 200)'),
ST_Intersection(ST_GeomFromText('LINESTRING(50 50, 50 150)'),ST_GeomFromText('POLYGON((30 50, 30 150, 70 150, 70 50, 30 50))')
)
));
the result is: MULTILINESTRING((50 49.9999999999999,50 50),(50 150,50 200))
Instead if I add another digit:
SELECT ST_AsText(
ST_Difference(
ST_GeomFromText('LINESTRING(50 49.99999999999999, 50 200)'),
ST_Intersection(ST_GeomFromText('LINESTRING(50 50, 50 150)'),ST_GeomFromText('POLYGON((30 50, 30 150, 70 150, 70 50, 30 50))')
)
));
the result is: MULTILINESTRING((50 50,50 50),(50 150,50 200))
and if I add another digit again
SELECT ST_AsText(
ST_Difference(
ST_GeomFromText('LINESTRING(50 49.999999999999999, 50 200)'),
ST_Intersection(ST_GeomFromText('LINESTRING(50 50, 50 150)'),ST_GeomFromText('POLYGON((30 50, 30 150, 70 150, 70 50, 30 50))')
)
));
the result is: LINESTRING(50 150,50 200)
I guess the second result is not correct because it return a multiline with a point.
I'm using debian lenny 32 bit with postgres 9.0.1 and Postgis trunk r6824 and geos svn r3222
Change History
Note: See
TracTickets for help on using
tickets.
