#5589 closed defect (fixed)

ST_3DDistance seems not to work for LINESTRINGs in specified situation.

Reported by: Wenjing Owned by: pramsey
Priority: critical Milestone: PostGIS 3.2.8
Component: postgis Version: 3.4.x
Keywords: Cc: Wenjing

Description (last modified by Wenjing)

Consider the following statement

SELECT ST_3DDistance(b1, b2)  
FROM ST_GeomFromText('LINESTRING Z (0 0 0, 1 0 0)') As b1,
ST_GeomFromText('LINESTRING Z (0 0 0, 1 1 1)') As b2;
--  st_3ddistance 
---------------
--              
-- (1 row)

The ST_3DDistance function is expected to give the result but it doesn't.

The version:

 POSTGIS="3.5.0dev 3.4.0rc1-705-g5c3ec8392" [EXTENSION] PGSQL="170" GEOS="3.13.0dev-CAPI-1.18.0" PROJ="8.2.1 NETWORK_ENABLED=OFF URL_ENDPOINT=https://c
dn.proj.org USER_WRITABLE_DIRECTORY=/tmp/proj DATABASE_PATH=/usr/share/proj/proj.db" LIBXML="2.9.13"
(1 row)

Change History (14)

comment:1 by Wenjing, 14 months ago

Summary: ST_3DDistance seems not to work for LINESTRINGs in specified situation.ST_3DDistance seems not work for LINESTRINGs in specified situation.

comment:2 by Wenjing, 14 months ago

Summary: ST_3DDistance seems not work for LINESTRINGs in specified situation.ST_3DDistance seems not to work for LINESTRINGs in specified situation.

comment:3 by Wenjing, 14 months ago

Cc: Wenjing added
Description: modified (diff)

comment:4 by robe, 14 months ago

I confirm this is not working and gives a NULL as you say. Very strange. Tested on 3.4.0 and 3.5.0

Last edited 14 months ago by robe (previous) (diff)

comment:5 by robe, 14 months ago

Milestone: PostGIS 3.5.0PostGIS 3.4.1

comment:6 by robe, 13 months ago

Milestone: PostGIS 3.4.1PostGIS 3.5.0

comment:7 by Wenjing, 11 months ago

Paul, did you have a chance to look at this one? It is very strange. @pramsey

comment:8 by pramsey, 10 months ago

I also see NULL. So.

comment:9 by Paul Ramsey <pramsey@…>, 10 months ago

In bccab952/git:

ST_3DDistance on segments with identical start, references #5589

comment:10 by Paul Ramsey <pramsey@…>, 10 months ago

In 94e5b95d/git:

ST_3DDistance error for shared first point, references #5589

comment:11 by Paul Ramsey <pramsey@…>, 10 months ago

In 5c276bc/git:

ST_3DDistance error for shared first point, references #5589

comment:12 by Paul Ramsey <pramsey@…>, 10 months ago

In 98d112f/git:

ST_3DDistance error for shared first point, references #5589

comment:13 by Paul Ramsey <pramsey@…>, 10 months ago

In 4425662/git:

ST_3DDistance error for shared first point, references #5589

comment:14 by pramsey, 10 months ago

Milestone: PostGIS 3.5.0PostGIS 3.2.8
Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.