Opened 10 months ago

Closed 10 months ago

Last modified 10 months ago

#5403 closed defect (fixed)

topology.ValidateTopology have a call to missing schema name function getringedges(unknown, integer) does not exist

Reported by: Lars Aksel Opsahl Owned by: strk
Priority: medium Milestone: PostGIS 3.2.6
Component: topology Version: 3.2.x
Keywords: Cc:

Description

To run topology.ValidateTopology(topo,bbox) you have set the topology path in psql (SET search_path TO "$user", topology, public;) or else I get the error below.

Running on

POSTGIS="3.4.0dev 3.3.0rc2-958-g4c776d418" [EXTENSION] PGSQL="120" GEOS="3.9.1-CAPI-1.14.2" SFCGAL="1.3.7" PROJ="7.2.1" LIBXML="2.9.10" LIBJSON="0.13.1" LIBPROTOBUF="1.3.3" WAGYU="0.5.0 (Internal)" TOPOLOGY

error message

ERROR:  42883: function getringedges(unknown, integer) does not exist
LINE 29:           GetRingEdges(
                   ^
HINT:  No function matches the given name and argument types. You might need to add explicit type casts.
QUERY:  
      WITH
      outside_point AS (
        SELECT ST_Translate(
          ST_StartPoint( ST_BoundingDiagonal(mbr) ),
          -1,
          -1
        )
        FROM prosj_mdir_hs_topo_v3.face
        WHERE face_id = $1
      ),
      leftmost_edge AS (
        SELECT
          CASE WHEN left_face = $1
          THEN
            edge_id
          ELSE
            -edge_id
          END ring_id
        FROM prosj_mdir_hs_topo_v3.edge
        WHERE left_face = $1 or right_face = $1
        ORDER BY
          geom <-> $2
        LIMIT 1
      ),
      edgering AS (
        SELECT *
        FROM
          GetRingEdges(
            'prosj_mdir_hs_topo_v3',
            (SELECT ring_id FROM leftmost_edge)
          )
      )
      SELECT
        ST_MakeLine(
          CASE WHEN r.edge > 0 THEN
            e.geom
          ELSE
            ST_Reverse(e.geom)
          END
          ORDER BY r.sequence
        ) outerRing
      FROM edgering r, prosj_mdir_hs_topo_v3.edge e
      WHERE e.edge_id = abs(r.edge)
    
CONTEXT:  PL/pgSQL function topology._validatetopologygetfaceshellmaximaledgering(character varying,integer) line 74 at EXECUTE
SQL statement "INSERT INTO pg_temp.face_check
    SELECT face_id,
      topology._ValidateTopologyGetFaceShellMaximalEdgeRing(toponame, face_id),
      mbr
    FROM face
    WHERE mbr && bbox
    AND (
      CASE WHEN invalid_faces IS NOT NULL THEN
        NOT face_id = ANY(invalid_faces)
      ELSE
        TRUE
      END
    )
    AND face_id NOT IN (
      SELECT face_id FROM pg_temp.face_check
    )"
PL/pgSQL function topology.validatetopology(character varying,geometry) line 336 at SQL statement
SQL statement "CREATE table prosj_mdir_hs_topo_v3.tables_grid_validate AS 
SELECT ARRAY_AGG(validate_topology) AS validate_result, cell_bbox, id 
FROM (
SELECT topology.ValidateTopology('prosj_mdir_hs_topo_v3',g.cell_bbox) AS validate_topology , 
g.cell_bbox, g.id 
FROM 
prosj_mdir_hs_topo_v3.multi_input_9_tables_grid g
WHERE EXISTS (SELECT 1 FROM prosj_mdir_hs_topo_v3.edge e WHERE ST_intersects(e.geom,g.cell_bbox) LIMIT 1)
order by id
) AS r
where id = 10 GROUP BY cell_bbox, id"
PL/pgSQL function inline_code_block line 7 at SQL statement
LOCATION:  ParseFuncOrColumn, parse_func.c:624


Change History (6)

comment:1 by strk, 10 months ago

Status: newassigned

Confirmed. I'm working on a focused testcase.

comment:2 by Sandro Santilli <strk@…>, 10 months ago

In 08952370/git:

Fully qualify internal calls to topology methods in ValidateTopology

References #5403 in master branch
Includes regress test

comment:3 by Sandro Santilli <strk@…>, 10 months ago

In 82421b9/git:

Fully qualify internal calls to topology methods in ValidateTopology

References #5403 in 3.3 branch (3.3.4dev)
Includes regress test

comment:4 by strk, 10 months ago

Milestone: PostGIS 3.3.4PostGIS 3.2.6
Version: 3.3.x3.2.x

Also 3.2.5 is affected

comment:5 by Sandro Santilli <strk@…>, 10 months ago

Resolution: fixed
Status: assignedclosed

In 04ac6f2/git:

Fully qualify internal calls to topology methods in ValidateTopology

Closes #5403 in 3.2 branch (3.2.6dev)
Includes regress test

comment:6 by Lars Aksel Opsahl, 10 months ago

Thanks for quick fix.

Note: See TracTickets for help on using tickets.