Opened 12 years ago

Closed 12 years ago

#1772 closed defect (fixed)

ST_Split returning NaN coordinates

Reported by: strk Owned by: pramsey
Priority: critical Milestone: PostGIS 2.0.1
Component: postgis Version: 2.0.x
Keywords: Cc:

Description

strk=# select ST_AsText(ST_Split( 'LINESTRING(0 1, 0 1, 0 1)', 'POINT(0 1)' ));
                           st_astext                           
---------------------------------------------------------------
 GEOMETRYCOLLECTION(LINESTRING(0 1),LINESTRING(-nan -nan,0 1))
(1 row)

The correct answer may be this one:

strk=# select ST_AsText(ST_Split( 'LINESTRING(0 1, 0 1)', 'POINT(0 1)' ));
                st_astext                
-----------------------------------------
 GEOMETRYCOLLECTION(LINESTRING(0 1,0 1))
(1 row)

Change History (4)

comment:1 by strk, 12 years ago

See #1771 for origin

comment:2 by strk, 12 years ago

Corollary:

select ST_Line_Locate_Point( 'LINESTRING(0 1, 0 1, 0 1)', 'POINT(0 1)');
 NaN

comment:3 by strk, 12 years ago

Fixed by r9630 — to be backported to 1.5 (the ST_Line_Locate_Point part)

comment:4 by strk, 12 years ago

Resolution: fixed
Status: newclosed

r9631 is the backport to 1.5

Note: See TracTickets for help on using tickets.