Ticket #1242 (closed defect: fixed)
Document bug or regression bug - ST_Line_Locate_Point for multilinestring
| Reported by: | robe | Owned by: | pramsey |
|---|---|---|---|
| Priority: | medium | Milestone: | PostGIS 1.5.4 |
| Component: | postgis | Version: | 1.5.X |
| Keywords: | Cc: |
Description
I thought Paul had revised this function in 1.5.1 to work with multilinestrings.
If I take the example and change it to:
http://www.postgis.org/docs/ST_Line_Locate_Point.html
SELECT ST_AsText(house_loc) As as_text_house_loc,
startstreet_num +
CAST( (endstreet_num - startstreet_num)
* ST_Line_Locate_Point(street_line, house_loc) As integer) As street_num
FROM
(SELECT ST_Multi(ST_GeomFromText('LINESTRING(1 2, 3 4)')) As street_line,
ST_MakePoint(x*1.01,y*1.03) As house_loc, 10 As startstreet_num,
20 As endstreet_num
FROM generate_series(1,3) x CROSS JOIN generate_series(2,4) As y)
As foo
WHERE ST_DWithin(street_line, house_loc, 0.2);
It gives a
ERROR: line_locate_point: 1st arg isnt a line
on both my 1.5.3 and 2.0 installs
Change History
Note: See
TracTickets for help on using
tickets.
