diff --git a/doc/astar/pgr_aStar.rst b/doc/astar/pgr_aStar.rst index a1ac395df46..9856dec8757 100644 --- a/doc/astar/pgr_aStar.rst +++ b/doc/astar/pgr_aStar.rst @@ -182,7 +182,7 @@ Many to Many | pgr_aStar(`Edges SQL`_, **start vids**, **end vids**, [**options**]) | **options:** ``[directed, heuristic, factor, epsilon]`` - | RETURNS SET OF |result-m-m| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: From vertices :math:`\{6, 8\}` to vertices :math:`\{10, 12\}` on a @@ -204,7 +204,7 @@ Combinations | pgr_aStar(`Edges SQL`_, `Combinations SQL`_, [**options**]) | **options:** ``[directed, heuristic, factor, epsilon]`` - | RETURNS SET OF |result-m-m| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: Using a combinations table on a **directed** graph with factor diff --git a/doc/bdAstar/pgr_bdAstar.rst b/doc/bdAstar/pgr_bdAstar.rst index dc6e5280c51..751065955c2 100644 --- a/doc/bdAstar/pgr_bdAstar.rst +++ b/doc/bdAstar/pgr_bdAstar.rst @@ -183,7 +183,7 @@ Many to Many | pgr_bdAstar(`Edges SQL`_, **start vids**, **end vids**, [**options**]) | **options:** ``[directed, heuristic, factor, epsilon]`` - | RETURNS SET OF |result-m-m| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: From vertices :math:`\{6, 8\}` to vertices :math:`\{10, 12\}` on a @@ -205,7 +205,7 @@ Combinations | pgr_bdAstar(`Edges SQL`_, `Combinations SQL`_, [**options**]) | **options:** ``[directed, heuristic, factor, epsilon]`` - | RETURNS SET OF |result-m-m| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: Using a combinations table on a **directed** graph with factor diff --git a/doc/bdDijkstra/pgr_bdDijkstra.rst b/doc/bdDijkstra/pgr_bdDijkstra.rst index cb4936dbad7..14ccba6f4a3 100644 --- a/doc/bdDijkstra/pgr_bdDijkstra.rst +++ b/doc/bdDijkstra/pgr_bdDijkstra.rst @@ -166,7 +166,7 @@ Many to Many | pgr_bdDijkstra(`Edges SQL`_, **start vids**, **end vids**, [``directed``]) - | RETURNS SET OF |result-m-m| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: From vertices :math:`\{6, 1\}` to vertices :math:`\{10, 17\}` on an @@ -187,7 +187,7 @@ Combinations | pgr_bdDijkstra(`Edges SQL`_, `Combinations SQL`_, [``directed``]) - | RETURNS SET OF |result-m-m| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: Using a combinations table on an **undirected** graph diff --git a/doc/bellman_ford/pgr_bellmanFord.rst b/doc/bellman_ford/pgr_bellmanFord.rst index 858742cf60c..d61c0f9f574 100644 --- a/doc/bellman_ford/pgr_bellmanFord.rst +++ b/doc/bellman_ford/pgr_bellmanFord.rst @@ -176,7 +176,7 @@ Many to Many | pgr_bellmanFord(`Edges SQL`_, **start vids**, **end vids**, [``directed``]) - | RETURNS SET OF |result-m-m| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: From vertices :math:`\{6, 1\}` to vertices :math:`\{10, 17\}` on an @@ -197,7 +197,7 @@ Combinations | pgr_bellmanFord(`Edges SQL`_, `Combinations SQL`_, [``directed``]) - | RETURNS SET OF |result-m-m| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: Using a combinations table on an **undirected** graph. diff --git a/doc/bellman_ford/pgr_edwardMoore.rst b/doc/bellman_ford/pgr_edwardMoore.rst index 66b53e434d4..29083f22c66 100644 --- a/doc/bellman_ford/pgr_edwardMoore.rst +++ b/doc/bellman_ford/pgr_edwardMoore.rst @@ -176,7 +176,7 @@ Many to Many | pgr_edwardMoore(`Edges SQL`_, **start vids**, **end vids**, [``directed``]); - | RETURNS SET OF |result-m-m| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: From vertices :math:`\{6, 1\}` to vertices :math:`\{10, 17\}` on an @@ -197,7 +197,7 @@ Combinations | pgr_edwardMoore(`Edges SQL`_, `Combinations SQL`_, [``directed``]); - | RETURNS SET OF |result-m-m| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: Using a combinations table on an **undirected** graph. diff --git a/doc/breadthFirstSearch/pgr_binaryBreadthFirstSearch.rst b/doc/breadthFirstSearch/pgr_binaryBreadthFirstSearch.rst index a1e196e8268..9ddffaeee00 100644 --- a/doc/breadthFirstSearch/pgr_binaryBreadthFirstSearch.rst +++ b/doc/breadthFirstSearch/pgr_binaryBreadthFirstSearch.rst @@ -175,7 +175,7 @@ Many to Many | pgr_binaryBreadthFirstSearch(`Edges SQL`_, **start vids**, **end vids**, [``directed``]) - | RETURNS SET OF |result-m-m| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: From vertices :math:`\{6, 1\}` to vertices :math:`\{10, 17\}` on an @@ -196,7 +196,7 @@ Combinations | pgr_binaryBreadthFirstSearch(`Edges SQL`_, `Combinations SQL`_, [``directed``]) - | RETURNS SET OF |result-m-m| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: Using a combinations table on an **undirected** graph diff --git a/doc/conf.py.in b/doc/conf.py.in index 01bc7dfcc24..097d77c1e27 100644 --- a/doc/conf.py.in +++ b/doc/conf.py.in @@ -356,15 +356,14 @@ rst_epilog=""" .. |ANY-INTEGER| replace:: :abbr:`ANY-INTEGER(SMALLINT, INTEGER, BIGINT)` .. |ANY-NUMERICAL| replace:: :abbr:`ANY-NUMERICAL(SMALLINT, INTEGER, BIGINT, REAL, FLOAT)` .. |generic-result| replace:: ``(seq, path_id, path_seq, start_vid, end_vid, node, edge, cost, agg_cost)`` -.. |ksp-result| replace:: ``(seq, path_id, path_seq, node, edge, cost, agg_cost)`` .. |short-generic-result| replace:: ``(seq, path_seq, start_vid, end_vid, node, edge, cost, agg_cost)`` .. |via-result| replace:: ``(seq, path_id, path_seq, start_vid, end_vid, node, edge, cost, agg_cost, route_agg_cost)`` .. |matrix-result| replace:: ``(start_vid, end_vid, agg_cost)`` +.. |ksp-result| replace:: ``(seq, path_id, path_seq, node, edge, cost, agg_cost)`` .. |old-generic-result| replace:: ``(seq, path_seq, [start_vid], [end_vid], node, edge, cost, agg_cost)`` .. |result-1-1| replace:: ``(seq, path_seq, node, edge, cost, agg_cost)`` .. |result-1-m| replace:: ``(seq, path_seq, end_vid, node, edge, cost, agg_cost)`` .. |result-m-1| replace:: ``(seq, path_seq, start_vid, node, edge, cost, agg_cost)`` -.. |result-m-m| replace:: ``(seq, path_seq, start_vid, end_vid, node, edge, cost, agg_cost)`` .. |result-bfs| replace:: ``(seq, depth, start_vid, node, edge, cost, agg_cost)`` .. |result-mst| replace:: ``(edge, cost)`` .. |result-1-1-no-seq| replace:: ``(seq, node, edge, cost, agg_cost)`` diff --git a/doc/dijkstra/pgr_dijkstra.rst b/doc/dijkstra/pgr_dijkstra.rst index 8514ff3223b..dda34aab141 100644 --- a/doc/dijkstra/pgr_dijkstra.rst +++ b/doc/dijkstra/pgr_dijkstra.rst @@ -164,7 +164,7 @@ Many to Many :class: signatures | pgr_dijkstra(`Edges SQL`_, **start vids**, **end vids** , [``directed``]) - | RETURNS SET OF |result-m-m| + | RETURNS SET OF |short-generic-result| | RETURNS (seq, path_seq, start vid, end vid, node, edge, cost, agg_cost) | OR EMPTY SET @@ -187,7 +187,7 @@ Combinations | pgr_dijkstra(`Edges SQL`_, `Combinations SQL`_ , [``directed``]) - | RETURNS SET OF |result-m-m| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: Using a combinations table on an **undirected** graph diff --git a/doc/dijkstra/pgr_dijkstraNear.rst b/doc/dijkstra/pgr_dijkstraNear.rst index d89992d4a5d..7c829eaebd9 100644 --- a/doc/dijkstra/pgr_dijkstraNear.rst +++ b/doc/dijkstra/pgr_dijkstraNear.rst @@ -88,9 +88,9 @@ Signatures :class: signatures | pgr_dijkstraNear(`Edges SQL`_, **start vid**, **end vids**, [**options A**]) - | pgr_dijkstraNear(`Edges SQL`_, **start vids**, **end vid** [**options A**]) - | pgr_dijkstraNear(`Edges SQL`_, **start vids**, **end vids** [**options B**]) - | pgr_dijkstraNear(`Edges SQL`_, `Combinations SQL`_ [**options B**]) + | pgr_dijkstraNear(`Edges SQL`_, **start vids**, **end vid**, [**options A**]) + | pgr_dijkstraNear(`Edges SQL`_, **start vids**, **end vids**, [**options B**]) + | pgr_dijkstraNear(`Edges SQL`_, `Combinations SQL`_, [**options B**]) | **options A:** ``[directed, cap]`` | **options B:** ``[directed, cap, global]`` diff --git a/doc/trsp/pgr_trsp.rst b/doc/trsp/pgr_trsp.rst index 4c675aed0cb..8c715c6d19d 100644 --- a/doc/trsp/pgr_trsp.rst +++ b/doc/trsp/pgr_trsp.rst @@ -101,7 +101,7 @@ Signatures | pgr_trsp(`Edges SQL`_, `Restrictions SQL`_, **start vids**, **end vids**, [directed]) | pgr_trsp(`Edges SQL`_, `Restrictions SQL`_, `Combinations SQL`_, [directed]) - | RETURNS SET OF |generic-result| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET .. index:: @@ -115,7 +115,7 @@ One to One pgr_trsp(`Edges SQL`_, `Restrictions SQL`_, **start vid**, **end vid**, [directed]) - | RETURNS SET OF |generic-result| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: From vertex :math:`6` to vertex :math:`10` on an undirected graph. @@ -135,7 +135,7 @@ One to Many pgr_trsp(`Edges SQL`_, `Restrictions SQL`_, **start vid**, **end vids**, [directed]) - | RETURNS SET OF |generic-result| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: From vertex :math:`6` to vertices :math:`\{10, 1\}` on an @@ -157,7 +157,7 @@ Many to One pgr_trsp(`Edges SQL`_, `Restrictions SQL`_, **start vids**, **end vid**, [directed]) - | RETURNS SET OF |generic-result| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: From vertices :math:`\{6, 1\}` to vertex :math:`8` on a directed @@ -179,7 +179,7 @@ Many to Many pgr_trsp(`Edges SQL`_, `Restrictions SQL`_, **start vids**, **end vids**, [directed]) - | RETURNS SET OF |generic-result| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: From vertices :math:`\{6, 1\}` to vertices :math:`\{10, 8\}` on an @@ -200,7 +200,7 @@ Combinations pgr_trsp(`Edges SQL`_, `Restrictions SQL`_, `Combinations SQL`_, [directed]) - | RETURNS SET OF |generic-result| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: Using a combinations table on an undirected graph. diff --git a/doc/trsp/pgr_trsp_withPoints.rst b/doc/trsp/pgr_trsp_withPoints.rst index 59b30015031..41cf3388ed7 100644 --- a/doc/trsp/pgr_trsp_withPoints.rst +++ b/doc/trsp/pgr_trsp_withPoints.rst @@ -88,7 +88,7 @@ Signatures :[options]: [directed, driving_side [details] - | RETURNS SET OF |generic-result| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET .. index:: @@ -103,7 +103,7 @@ One to One pgr_trsp_withPoints(`Edges SQL`_, `Restrictions SQL`_, `Points SQL`_, **start vid**, **end vid**, [directed, driving_side, details]) - | RETURNS SET OF |generic-result| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: From point :math:`1` to vertex :math:`10` with details on a left @@ -125,7 +125,7 @@ One to Many pgr_trsp_withPoints(`Edges SQL`_, `Restrictions SQL`_, `Points SQL`_, **start vid**, **end vids** [directed, driving_side, details]) - | RETURNS SET OF |generic-result| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: From point :math:`1` to point :math:`3` and vertex :math:`7`. @@ -146,7 +146,7 @@ Many to One pgr_trsp_withPoints(`Edges SQL`_, `Restrictions SQL`_, `Points SQL`_, **start vids**, **end vid** [directed, driving_side, details]) - | RETURNS SET OF |generic-result| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: From point :math:`1` and vertex :math:`6` to point :math:`3`. @@ -167,7 +167,7 @@ Many to Many pgr_trsp_withPoints(`Edges SQL`_, `Restrictions SQL`_, `Points SQL`_, **start vids**, **end vids** [directed, driving_side, details]) - | RETURNS SET OF |generic-result| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: From point :math:`1` and vertex :math:`6` to point :math:`3` and @@ -189,7 +189,7 @@ Combinations pgr_trsp_withPoints(`Edges SQL`_, `Restrictions SQL`_, `Combinations SQL`_, `Points SQL`_, [directed, driving_side, details]) - | RETURNS SET OF |generic-result| + | RETURNS SET OF |short-generic-result| | OR EMPTY SET :Example: From point :math:`1` to vertex :math:`10` and from vertex :math:`6` to diff --git a/docqueries/src/migration.result b/docqueries/src/migration.result index a05839daa3d..39190666065 100644 --- a/docqueries/src/migration.result +++ b/docqueries/src/migration.result @@ -131,14 +131,14 @@ SELECT * FROM pgr_trsp( FROM edges WHERE id != 16$$, $$SELECT * FROM new_restrictions$$, 15, 16); - seq | path_id | path_seq | start_vid | end_vid | node | edge | cost | agg_cost ------+---------+----------+-----------+---------+------+------+------+---------- - 1 | 1 | 1 | 15 | 16 | 15 | 3 | 1 | 0 - 2 | 1 | 2 | 15 | 16 | 10 | 5 | 1 | 1 - 3 | 1 | 3 | 15 | 16 | 11 | 11 | 1 | 2 - 4 | 1 | 4 | 15 | 16 | 12 | 13 | 1 | 3 - 5 | 1 | 5 | 15 | 16 | 17 | 15 | 1 | 4 - 6 | 1 | 6 | 15 | 16 | 16 | -1 | 0 | 5 + seq | path_seq | start_vid | end_vid | node | edge | cost | agg_cost +-----+----------+-----------+---------+------+------+------+---------- + 1 | 1 | 15 | 16 | 15 | 3 | 1 | 0 + 2 | 2 | 15 | 16 | 10 | 5 | 1 | 1 + 3 | 3 | 15 | 16 | 11 | 11 | 1 | 2 + 4 | 4 | 15 | 16 | 12 | 13 | 1 | 3 + 5 | 5 | 15 | 16 | 17 | 15 | 1 | 4 + 6 | 6 | 15 | 16 | 16 | -1 | 0 | 5 (6 rows) /* --verticesv6 */ @@ -241,19 +241,19 @@ SELECT * FROM pgr_trsp_withPoints( $$SELECT pid, edge_id, fraction FROM pointsOfInterest WHERE pid IN (4, 3)$$, -4, -3, details => false); - seq | path_id | path_seq | start_vid | end_vid | node | edge | cost | agg_cost ------+---------+----------+-----------+---------+------+------+------+---------- - 1 | 1 | 1 | -4 | -3 | -4 | 6 | 0.7 | 0 - 2 | 1 | 2 | -4 | -3 | 3 | 7 | 1 | 0.7 - 3 | 1 | 3 | -4 | -3 | 7 | 8 | 1 | 1.7 - 4 | 1 | 4 | -4 | -3 | 11 | 9 | 1 | 2.7 - 5 | 1 | 5 | -4 | -3 | 16 | 16 | 1 | 3.7 - 6 | 1 | 6 | -4 | -3 | 15 | 3 | 1 | 4.7 - 7 | 1 | 7 | -4 | -3 | 10 | 2 | 1 | 5.7 - 8 | 1 | 8 | -4 | -3 | 6 | 4 | 1 | 6.7 - 9 | 1 | 9 | -4 | -3 | 7 | 10 | 1 | 7.7 - 10 | 1 | 10 | -4 | -3 | 8 | 12 | 0.6 | 8.7 - 11 | 1 | 11 | -4 | -3 | -3 | -1 | 0 | 9.3 + seq | path_seq | start_vid | end_vid | node | edge | cost | agg_cost +-----+----------+-----------+---------+------+------+------+---------- + 1 | 1 | -4 | -3 | -4 | 6 | 0.7 | 0 + 2 | 2 | -4 | -3 | 3 | 7 | 1 | 0.7 + 3 | 3 | -4 | -3 | 7 | 8 | 1 | 1.7 + 4 | 4 | -4 | -3 | 11 | 9 | 1 | 2.7 + 5 | 5 | -4 | -3 | 16 | 16 | 1 | 3.7 + 6 | 6 | -4 | -3 | 15 | 3 | 1 | 4.7 + 7 | 7 | -4 | -3 | 10 | 2 | 1 | 5.7 + 8 | 8 | -4 | -3 | 6 | 4 | 1 | 6.7 + 9 | 9 | -4 | -3 | 7 | 10 | 1 | 7.7 + 10 | 10 | -4 | -3 | 8 | 12 | 0.6 | 8.7 + 11 | 11 | -4 | -3 | -3 | -1 | 0 | 9.3 (11 rows) /* --edgesv6 */ diff --git a/docqueries/trsp/doc-trsp.result b/docqueries/trsp/doc-trsp.result index e2d6bf2e49c..81064067c32 100644 --- a/docqueries/trsp/doc-trsp.result +++ b/docqueries/trsp/doc-trsp.result @@ -8,10 +8,10 @@ SELECT * FROM pgr_trsp( $$SELECT path, cost FROM restrictions$$, 6, 10, false); - seq | path_id | path_seq | start_vid | end_vid | node | edge | cost | agg_cost ------+---------+----------+-----------+---------+------+------+------+---------- - 1 | 1 | 1 | 6 | 10 | 6 | 2 | 1 | 0 - 2 | 1 | 2 | 6 | 10 | 10 | -1 | 0 | 1 + seq | path_seq | start_vid | end_vid | node | edge | cost | agg_cost +-----+----------+-----------+---------+------+------+------+---------- + 1 | 1 | 6 | 10 | 6 | 2 | 1 | 0 + 2 | 2 | 6 | 10 | 10 | -1 | 0 | 1 (2 rows) /* -- q3 */ @@ -20,20 +20,20 @@ SELECT * FROM pgr_trsp( $$SELECT * FROM restrictions$$, 6, ARRAY[10, 1], false); - seq | path_id | path_seq | start_vid | end_vid | node | edge | cost | agg_cost ------+---------+----------+-----------+---------+------+------+------+---------- - 1 | 1 | 1 | 6 | 1 | 6 | 4 | 1 | 0 - 2 | 1 | 2 | 6 | 1 | 7 | 10 | 1 | 1 - 3 | 1 | 3 | 6 | 1 | 8 | 12 | 1 | 2 - 4 | 1 | 4 | 6 | 1 | 12 | 11 | 1 | 3 - 5 | 1 | 5 | 6 | 1 | 11 | 8 | 1 | 4 - 6 | 1 | 6 | 6 | 1 | 7 | 7 | 1 | 5 - 7 | 1 | 7 | 6 | 1 | 3 | 6 | 1 | 6 - 8 | 1 | 8 | 6 | 1 | 1 | -1 | 0 | 7 - 9 | 2 | 1 | 6 | 10 | 6 | 4 | 1 | 0 - 10 | 2 | 2 | 6 | 10 | 7 | 8 | 1 | 1 - 11 | 2 | 3 | 6 | 10 | 11 | 5 | 1 | 2 - 12 | 2 | 4 | 6 | 10 | 10 | -1 | 0 | 3 + seq | path_seq | start_vid | end_vid | node | edge | cost | agg_cost +-----+----------+-----------+---------+------+------+------+---------- + 1 | 1 | 6 | 1 | 6 | 4 | 1 | 0 + 2 | 2 | 6 | 1 | 7 | 10 | 1 | 1 + 3 | 3 | 6 | 1 | 8 | 12 | 1 | 2 + 4 | 4 | 6 | 1 | 12 | 11 | 1 | 3 + 5 | 5 | 6 | 1 | 11 | 8 | 1 | 4 + 6 | 6 | 6 | 1 | 7 | 7 | 1 | 5 + 7 | 7 | 6 | 1 | 3 | 6 | 1 | 6 + 8 | 8 | 6 | 1 | 1 | -1 | 0 | 7 + 9 | 1 | 6 | 10 | 6 | 4 | 1 | 0 + 10 | 2 | 6 | 10 | 7 | 8 | 1 | 1 + 11 | 3 | 6 | 10 | 11 | 5 | 1 | 2 + 12 | 4 | 6 | 10 | 10 | -1 | 0 | 3 (12 rows) /* -- q4 */ @@ -41,15 +41,15 @@ SELECT * FROM pgr_trsp( $$SELECT id, source, target, cost, reverse_cost FROM edges$$, $$SELECT path, cost FROM restrictions$$, ARRAY[6, 1], 8); - seq | path_id | path_seq | start_vid | end_vid | node | edge | cost | agg_cost ------+---------+----------+-----------+---------+------+------+------+---------- - 1 | 1 | 1 | 1 | 8 | 1 | 6 | 1 | 0 - 2 | 1 | 2 | 1 | 8 | 3 | 7 | 1 | 1 - 3 | 1 | 3 | 1 | 8 | 7 | 10 | 101 | 2 - 4 | 1 | 4 | 1 | 8 | 8 | -1 | 0 | 103 - 5 | 2 | 1 | 6 | 8 | 6 | 4 | 1 | 0 - 6 | 2 | 2 | 6 | 8 | 7 | 10 | 1 | 1 - 7 | 2 | 3 | 6 | 8 | 8 | -1 | 0 | 2 + seq | path_seq | start_vid | end_vid | node | edge | cost | agg_cost +-----+----------+-----------+---------+------+------+------+---------- + 1 | 1 | 1 | 8 | 1 | 6 | 1 | 0 + 2 | 2 | 1 | 8 | 3 | 7 | 1 | 1 + 3 | 3 | 1 | 8 | 7 | 10 | 101 | 2 + 4 | 4 | 1 | 8 | 8 | -1 | 0 | 103 + 5 | 1 | 6 | 8 | 6 | 4 | 1 | 0 + 6 | 2 | 6 | 8 | 7 | 10 | 1 | 1 + 7 | 3 | 6 | 8 | 8 | -1 | 0 | 2 (7 rows) /* -- q5 */ @@ -58,26 +58,26 @@ SELECT * FROM pgr_trsp( $$SELECT path, cost FROM restrictions$$, ARRAY[6, 1], ARRAY[10, 8], false); - seq | path_id | path_seq | start_vid | end_vid | node | edge | cost | agg_cost ------+---------+----------+-----------+---------+------+------+------+---------- - 1 | 1 | 1 | 1 | 8 | 1 | 6 | 1 | 0 - 2 | 1 | 2 | 1 | 8 | 3 | 7 | 1 | 1 - 3 | 1 | 3 | 1 | 8 | 7 | 4 | 1 | 2 - 4 | 1 | 4 | 1 | 8 | 6 | 2 | 1 | 3 - 5 | 1 | 5 | 1 | 8 | 10 | 5 | 1 | 4 - 6 | 1 | 6 | 1 | 8 | 11 | 11 | 1 | 5 - 7 | 1 | 7 | 1 | 8 | 12 | 12 | 1 | 6 - 8 | 1 | 8 | 1 | 8 | 8 | -1 | 0 | 7 - 9 | 2 | 1 | 1 | 10 | 1 | 6 | 1 | 0 - 10 | 2 | 2 | 1 | 10 | 3 | 7 | 1 | 1 - 11 | 2 | 3 | 1 | 10 | 7 | 4 | 1 | 2 - 12 | 2 | 4 | 1 | 10 | 6 | 2 | 1 | 3 - 13 | 2 | 5 | 1 | 10 | 10 | -1 | 0 | 4 - 14 | 3 | 1 | 6 | 8 | 6 | 4 | 1 | 0 - 15 | 3 | 2 | 6 | 8 | 7 | 10 | 1 | 1 - 16 | 3 | 3 | 6 | 8 | 8 | -1 | 0 | 2 - 17 | 4 | 1 | 6 | 10 | 6 | 2 | 1 | 0 - 18 | 4 | 2 | 6 | 10 | 10 | -1 | 0 | 1 + seq | path_seq | start_vid | end_vid | node | edge | cost | agg_cost +-----+----------+-----------+---------+------+------+------+---------- + 1 | 1 | 1 | 8 | 1 | 6 | 1 | 0 + 2 | 2 | 1 | 8 | 3 | 7 | 1 | 1 + 3 | 3 | 1 | 8 | 7 | 4 | 1 | 2 + 4 | 4 | 1 | 8 | 6 | 2 | 1 | 3 + 5 | 5 | 1 | 8 | 10 | 5 | 1 | 4 + 6 | 6 | 1 | 8 | 11 | 11 | 1 | 5 + 7 | 7 | 1 | 8 | 12 | 12 | 1 | 6 + 8 | 8 | 1 | 8 | 8 | -1 | 0 | 7 + 9 | 1 | 1 | 10 | 1 | 6 | 1 | 0 + 10 | 2 | 1 | 10 | 3 | 7 | 1 | 1 + 11 | 3 | 1 | 10 | 7 | 4 | 1 | 2 + 12 | 4 | 1 | 10 | 6 | 2 | 1 | 3 + 13 | 5 | 1 | 10 | 10 | -1 | 0 | 4 + 14 | 1 | 6 | 8 | 6 | 4 | 1 | 0 + 15 | 2 | 6 | 8 | 7 | 10 | 1 | 1 + 16 | 3 | 6 | 8 | 8 | -1 | 0 | 2 + 17 | 1 | 6 | 10 | 6 | 2 | 1 | 0 + 18 | 2 | 6 | 10 | 10 | -1 | 0 | 1 (18 rows) /* -- q6 */ @@ -85,33 +85,33 @@ SELECT * FROM pgr_trsp( $$SELECT id, source, target, cost, reverse_cost FROM edges$$, $$SELECT path, cost FROM restrictions$$, $$SELECT * FROM (VALUES (6, 10), (6, 1), (6, 8), (1, 8)) AS combinations (source, target)$$); - seq | path_id | path_seq | start_vid | end_vid | node | edge | cost | agg_cost ------+---------+----------+-----------+---------+------+------+------+---------- - 1 | 1 | 1 | 1 | 8 | 1 | 6 | 1 | 0 - 2 | 1 | 2 | 1 | 8 | 3 | 7 | 1 | 1 - 3 | 1 | 3 | 1 | 8 | 7 | 10 | 101 | 2 - 4 | 1 | 4 | 1 | 8 | 8 | -1 | 0 | 103 - 5 | 2 | 1 | 6 | 1 | 6 | 4 | 1 | 0 - 6 | 2 | 2 | 6 | 1 | 7 | 10 | 1 | 1 - 7 | 2 | 3 | 6 | 1 | 8 | 12 | 1 | 2 - 8 | 2 | 4 | 6 | 1 | 12 | 13 | 1 | 3 - 9 | 2 | 5 | 6 | 1 | 17 | 15 | 1 | 4 - 10 | 2 | 6 | 6 | 1 | 16 | 9 | 1 | 5 - 11 | 2 | 7 | 6 | 1 | 11 | 8 | 1 | 6 - 12 | 2 | 8 | 6 | 1 | 7 | 7 | 1 | 7 - 13 | 2 | 9 | 6 | 1 | 3 | 6 | 1 | 8 - 14 | 2 | 10 | 6 | 1 | 1 | -1 | 0 | 9 - 15 | 3 | 1 | 6 | 8 | 6 | 4 | 1 | 0 - 16 | 3 | 2 | 6 | 8 | 7 | 10 | 1 | 1 - 17 | 3 | 3 | 6 | 8 | 8 | -1 | 0 | 2 - 18 | 4 | 1 | 6 | 10 | 6 | 4 | 1 | 0 - 19 | 4 | 2 | 6 | 10 | 7 | 10 | 1 | 1 - 20 | 4 | 3 | 6 | 10 | 8 | 12 | 1 | 2 - 21 | 4 | 4 | 6 | 10 | 12 | 13 | 1 | 3 - 22 | 4 | 5 | 6 | 10 | 17 | 15 | 1 | 4 - 23 | 4 | 6 | 6 | 10 | 16 | 16 | 1 | 5 - 24 | 4 | 7 | 6 | 10 | 15 | 3 | 1 | 6 - 25 | 4 | 8 | 6 | 10 | 10 | -1 | 0 | 7 + seq | path_seq | start_vid | end_vid | node | edge | cost | agg_cost +-----+----------+-----------+---------+------+------+------+---------- + 1 | 1 | 1 | 8 | 1 | 6 | 1 | 0 + 2 | 2 | 1 | 8 | 3 | 7 | 1 | 1 + 3 | 3 | 1 | 8 | 7 | 10 | 101 | 2 + 4 | 4 | 1 | 8 | 8 | -1 | 0 | 103 + 5 | 1 | 6 | 1 | 6 | 4 | 1 | 0 + 6 | 2 | 6 | 1 | 7 | 10 | 1 | 1 + 7 | 3 | 6 | 1 | 8 | 12 | 1 | 2 + 8 | 4 | 6 | 1 | 12 | 13 | 1 | 3 + 9 | 5 | 6 | 1 | 17 | 15 | 1 | 4 + 10 | 6 | 6 | 1 | 16 | 9 | 1 | 5 + 11 | 7 | 6 | 1 | 11 | 8 | 1 | 6 + 12 | 8 | 6 | 1 | 7 | 7 | 1 | 7 + 13 | 9 | 6 | 1 | 3 | 6 | 1 | 8 + 14 | 10 | 6 | 1 | 1 | -1 | 0 | 9 + 15 | 1 | 6 | 8 | 6 | 4 | 1 | 0 + 16 | 2 | 6 | 8 | 7 | 10 | 1 | 1 + 17 | 3 | 6 | 8 | 8 | -1 | 0 | 2 + 18 | 1 | 6 | 10 | 6 | 4 | 1 | 0 + 19 | 2 | 6 | 10 | 7 | 10 | 1 | 1 + 20 | 3 | 6 | 10 | 8 | 12 | 1 | 2 + 21 | 4 | 6 | 10 | 12 | 13 | 1 | 3 + 22 | 5 | 6 | 10 | 17 | 15 | 1 | 4 + 23 | 6 | 6 | 10 | 16 | 16 | 1 | 5 + 24 | 7 | 6 | 10 | 15 | 3 | 1 | 6 + 25 | 8 | 6 | 10 | 10 | -1 | 0 | 7 (25 rows) /* -- q7 */ diff --git a/docqueries/trsp/trsp_withPoints.result b/docqueries/trsp/trsp_withPoints.result index dfd39d93d76..2f075e28983 100644 --- a/docqueries/trsp/trsp_withPoints.result +++ b/docqueries/trsp/trsp_withPoints.result @@ -11,20 +11,20 @@ SELECT * FROM pgr_trsp_withPoints( $$SELECT pid, edge_id, fraction, side FROM pointsOfInterest$$, -1, 10, details => true); - seq | path_id | path_seq | start_vid | end_vid | node | edge | cost | agg_cost ------+---------+----------+-----------+---------+------+------+------+---------- - 1 | 1 | 1 | -1 | 10 | -1 | 1 | 0.4 | 0 - 2 | 1 | 2 | -1 | 10 | 5 | 1 | 1 | 0.4 - 3 | 1 | 3 | -1 | 10 | 6 | 4 | 0.7 | 1.4 - 4 | 1 | 4 | -1 | 10 | -6 | 4 | 0.3 | 2.1 - 5 | 1 | 5 | -1 | 10 | 7 | 8 | 1 | 2.4 - 6 | 1 | 6 | -1 | 10 | 11 | 9 | 1 | 3.4 - 7 | 1 | 7 | -1 | 10 | 16 | 15 | 0.4 | 4.4 - 8 | 1 | 8 | -1 | 10 | -2 | 15 | 0.6 | 4.8 - 9 | 1 | 9 | -1 | 10 | 17 | 15 | 1 | 5.4 - 10 | 1 | 10 | -1 | 10 | 16 | 16 | 1 | 6.4 - 11 | 1 | 11 | -1 | 10 | 15 | 3 | 1 | 7.4 - 12 | 1 | 12 | -1 | 10 | 10 | -1 | 0 | 8.4 + seq | path_seq | start_vid | end_vid | node | edge | cost | agg_cost +-----+----------+-----------+---------+------+------+------+---------- + 1 | 1 | -1 | 10 | -1 | 1 | 0.4 | 0 + 2 | 2 | -1 | 10 | 5 | 1 | 1 | 0.4 + 3 | 3 | -1 | 10 | 6 | 4 | 0.7 | 1.4 + 4 | 4 | -1 | 10 | -6 | 4 | 0.3 | 2.1 + 5 | 5 | -1 | 10 | 7 | 8 | 1 | 2.4 + 6 | 6 | -1 | 10 | 11 | 9 | 1 | 3.4 + 7 | 7 | -1 | 10 | 16 | 15 | 0.4 | 4.4 + 8 | 8 | -1 | 10 | -2 | 15 | 0.6 | 4.8 + 9 | 9 | -1 | 10 | 17 | 15 | 1 | 5.4 + 10 | 10 | -1 | 10 | 16 | 16 | 1 | 6.4 + 11 | 11 | -1 | 10 | 15 | 3 | 1 | 7.4 + 12 | 12 | -1 | 10 | 10 | -1 | 0 | 8.4 (12 rows) /* --e2 */ @@ -33,16 +33,16 @@ SELECT * FROM pgr_trsp_withPoints( $$SELECT id, path, cost FROM restrictions$$, $$SELECT pid, edge_id, fraction, side FROM pointsOfInterest$$, -1, ARRAY[-3, 7]); - seq | path_id | path_seq | start_vid | end_vid | node | edge | cost | agg_cost ------+---------+----------+-----------+---------+------+------+------+---------- - 1 | 1 | 1 | -1 | -3 | -1 | 1 | 1.4 | 0 - 2 | 1 | 2 | -1 | -3 | 6 | 4 | 1 | 1.4 - 3 | 1 | 3 | -1 | -3 | 7 | 10 | 1 | 2.4 - 4 | 1 | 4 | -1 | -3 | 8 | 12 | 0.6 | 3.4 - 5 | 1 | 5 | -1 | -3 | -3 | -1 | 0 | 4 - 6 | 2 | 1 | -1 | 7 | -1 | 1 | 1.4 | 0 - 7 | 2 | 2 | -1 | 7 | 6 | 4 | 1 | 1.4 - 8 | 2 | 3 | -1 | 7 | 7 | -1 | 0 | 2.4 + seq | path_seq | start_vid | end_vid | node | edge | cost | agg_cost +-----+----------+-----------+---------+------+------+------+---------- + 1 | 1 | -1 | -3 | -1 | 1 | 1.4 | 0 + 2 | 2 | -1 | -3 | 6 | 4 | 1 | 1.4 + 3 | 3 | -1 | -3 | 7 | 10 | 1 | 2.4 + 4 | 4 | -1 | -3 | 8 | 12 | 0.6 | 3.4 + 5 | 5 | -1 | -3 | -3 | -1 | 0 | 4 + 6 | 1 | -1 | 7 | -1 | 1 | 1.4 | 0 + 7 | 2 | -1 | 7 | 6 | 4 | 1 | 1.4 + 8 | 3 | -1 | 7 | 7 | -1 | 0 | 2.4 (8 rows) /* --e3 */ @@ -51,17 +51,17 @@ SELECT * FROM pgr_trsp_withPoints( $$SELECT id, path, cost FROM restrictions$$, $$SELECT pid, edge_id, fraction, side FROM pointsOfInterest$$, ARRAY[-1, 6], -3); - seq | path_id | path_seq | start_vid | end_vid | node | edge | cost | agg_cost ------+---------+----------+-----------+---------+------+------+------+---------- - 1 | 1 | 1 | -1 | -3 | -1 | 1 | 1.4 | 0 - 2 | 1 | 2 | -1 | -3 | 6 | 4 | 1 | 1.4 - 3 | 1 | 3 | -1 | -3 | 7 | 10 | 1 | 2.4 - 4 | 1 | 4 | -1 | -3 | 8 | 12 | 0.6 | 3.4 - 5 | 1 | 5 | -1 | -3 | -3 | -1 | 0 | 4 - 6 | 2 | 1 | 6 | -3 | 6 | 4 | 1 | 0 - 7 | 2 | 2 | 6 | -3 | 7 | 10 | 1 | 1 - 8 | 2 | 3 | 6 | -3 | 8 | 12 | 0.6 | 2 - 9 | 2 | 4 | 6 | -3 | -3 | -1 | 0 | 2.6 + seq | path_seq | start_vid | end_vid | node | edge | cost | agg_cost +-----+----------+-----------+---------+------+------+------+---------- + 1 | 1 | -1 | -3 | -1 | 1 | 1.4 | 0 + 2 | 2 | -1 | -3 | 6 | 4 | 1 | 1.4 + 3 | 3 | -1 | -3 | 7 | 10 | 1 | 2.4 + 4 | 4 | -1 | -3 | 8 | 12 | 0.6 | 3.4 + 5 | 5 | -1 | -3 | -3 | -1 | 0 | 4 + 6 | 1 | 6 | -3 | 6 | 4 | 1 | 0 + 7 | 2 | 6 | -3 | 7 | 10 | 1 | 1 + 8 | 3 | 6 | -3 | 8 | 12 | 0.6 | 2 + 9 | 4 | 6 | -3 | -3 | -1 | 0 | 2.6 (9 rows) /* --e4 */ @@ -70,37 +70,37 @@ SELECT * FROM pgr_trsp_withPoints( $$SELECT id, path, cost FROM restrictions$$, $$SELECT pid, edge_id, fraction, side FROM pointsOfInterest$$, ARRAY[-1, 6], ARRAY[-3, 1]); - seq | path_id | path_seq | start_vid | end_vid | node | edge | cost | agg_cost ------+---------+----------+-----------+---------+------+------+------+---------- - 1 | 1 | 1 | -1 | -3 | -1 | 1 | 1.4 | 0 - 2 | 1 | 2 | -1 | -3 | 6 | 4 | 1 | 1.4 - 3 | 1 | 3 | -1 | -3 | 7 | 10 | 1 | 2.4 - 4 | 1 | 4 | -1 | -3 | 8 | 12 | 0.6 | 3.4 - 5 | 1 | 5 | -1 | -3 | -3 | -1 | 0 | 4 - 6 | 2 | 1 | -1 | 1 | -1 | 1 | 1.4 | 0 - 7 | 2 | 2 | -1 | 1 | 6 | 4 | 1 | 1.4 - 8 | 2 | 3 | -1 | 1 | 7 | 8 | 1 | 2.4 - 9 | 2 | 4 | -1 | 1 | 11 | 9 | 1 | 3.4 - 10 | 2 | 5 | -1 | 1 | 16 | 15 | 2 | 4.4 - 11 | 2 | 6 | -1 | 1 | 16 | 9 | 1 | 6.4 - 12 | 2 | 7 | -1 | 1 | 11 | 8 | 1 | 7.4 - 13 | 2 | 8 | -1 | 1 | 7 | 7 | 1 | 8.4 - 14 | 2 | 9 | -1 | 1 | 3 | 6 | 1 | 9.4 - 15 | 2 | 10 | -1 | 1 | 1 | -1 | 0 | 10.4 - 16 | 3 | 1 | 6 | -3 | 6 | 4 | 1 | 0 - 17 | 3 | 2 | 6 | -3 | 7 | 10 | 1 | 1 - 18 | 3 | 3 | 6 | -3 | 8 | 12 | 0.6 | 2 - 19 | 3 | 4 | 6 | -3 | -3 | -1 | 0 | 2.6 - 20 | 4 | 1 | 6 | 1 | 6 | 4 | 1 | 0 - 21 | 4 | 2 | 6 | 1 | 7 | 10 | 1 | 1 - 22 | 4 | 3 | 6 | 1 | 8 | 12 | 1 | 2 - 23 | 4 | 4 | 6 | 1 | 12 | 13 | 1 | 3 - 24 | 4 | 5 | 6 | 1 | 17 | 15 | 1 | 4 - 25 | 4 | 6 | 6 | 1 | 16 | 9 | 1 | 5 - 26 | 4 | 7 | 6 | 1 | 11 | 8 | 1 | 6 - 27 | 4 | 8 | 6 | 1 | 7 | 7 | 1 | 7 - 28 | 4 | 9 | 6 | 1 | 3 | 6 | 1 | 8 - 29 | 4 | 10 | 6 | 1 | 1 | -1 | 0 | 9 + seq | path_seq | start_vid | end_vid | node | edge | cost | agg_cost +-----+----------+-----------+---------+------+------+------+---------- + 1 | 1 | -1 | -3 | -1 | 1 | 1.4 | 0 + 2 | 2 | -1 | -3 | 6 | 4 | 1 | 1.4 + 3 | 3 | -1 | -3 | 7 | 10 | 1 | 2.4 + 4 | 4 | -1 | -3 | 8 | 12 | 0.6 | 3.4 + 5 | 5 | -1 | -3 | -3 | -1 | 0 | 4 + 6 | 1 | -1 | 1 | -1 | 1 | 1.4 | 0 + 7 | 2 | -1 | 1 | 6 | 4 | 1 | 1.4 + 8 | 3 | -1 | 1 | 7 | 8 | 1 | 2.4 + 9 | 4 | -1 | 1 | 11 | 9 | 1 | 3.4 + 10 | 5 | -1 | 1 | 16 | 15 | 2 | 4.4 + 11 | 6 | -1 | 1 | 16 | 9 | 1 | 6.4 + 12 | 7 | -1 | 1 | 11 | 8 | 1 | 7.4 + 13 | 8 | -1 | 1 | 7 | 7 | 1 | 8.4 + 14 | 9 | -1 | 1 | 3 | 6 | 1 | 9.4 + 15 | 10 | -1 | 1 | 1 | -1 | 0 | 10.4 + 16 | 1 | 6 | -3 | 6 | 4 | 1 | 0 + 17 | 2 | 6 | -3 | 7 | 10 | 1 | 1 + 18 | 3 | 6 | -3 | 8 | 12 | 0.6 | 2 + 19 | 4 | 6 | -3 | -3 | -1 | 0 | 2.6 + 20 | 1 | 6 | 1 | 6 | 4 | 1 | 0 + 21 | 2 | 6 | 1 | 7 | 10 | 1 | 1 + 22 | 3 | 6 | 1 | 8 | 12 | 1 | 2 + 23 | 4 | 6 | 1 | 12 | 13 | 1 | 3 + 24 | 5 | 6 | 1 | 17 | 15 | 1 | 4 + 25 | 6 | 6 | 1 | 16 | 9 | 1 | 5 + 26 | 7 | 6 | 1 | 11 | 8 | 1 | 6 + 27 | 8 | 6 | 1 | 7 | 7 | 1 | 7 + 28 | 9 | 6 | 1 | 3 | 6 | 1 | 8 + 29 | 10 | 6 | 1 | 1 | -1 | 0 | 9 (29 rows) /* --e5 */ @@ -111,25 +111,25 @@ SELECT * FROM pgr_trsp_withPoints( $$SELECT * FROM (VALUES (-1, 10), (6, -3)) AS t(source, target)$$, driving_side => 'r', details => true); - seq | path_id | path_seq | start_vid | end_vid | node | edge | cost | agg_cost ------+---------+----------+-----------+---------+------+------+------+---------- - 1 | 1 | 1 | -1 | 10 | -1 | 1 | 0.4 | 0 - 2 | 1 | 2 | -1 | 10 | 5 | 1 | 1 | 0.4 - 3 | 1 | 3 | -1 | 10 | 6 | 4 | 0.7 | 1.4 - 4 | 1 | 4 | -1 | 10 | -6 | 4 | 0.3 | 2.1 - 5 | 1 | 5 | -1 | 10 | 7 | 8 | 1 | 2.4 - 6 | 1 | 6 | -1 | 10 | 11 | 9 | 1 | 3.4 - 7 | 1 | 7 | -1 | 10 | 16 | 15 | 0.4 | 4.4 - 8 | 1 | 8 | -1 | 10 | -2 | 15 | 0.6 | 4.8 - 9 | 1 | 9 | -1 | 10 | 17 | 15 | 1 | 5.4 - 10 | 1 | 10 | -1 | 10 | 16 | 16 | 1 | 6.4 - 11 | 1 | 11 | -1 | 10 | 15 | 3 | 1 | 7.4 - 12 | 1 | 12 | -1 | 10 | 10 | -1 | 0 | 8.4 - 13 | 2 | 1 | 6 | -3 | 6 | 4 | 0.7 | 0 - 14 | 2 | 2 | 6 | -3 | -6 | 4 | 0.3 | 0.7 - 15 | 2 | 3 | 6 | -3 | 7 | 10 | 1 | 1 - 16 | 2 | 4 | 6 | -3 | 8 | 12 | 0.6 | 2 - 17 | 2 | 5 | 6 | -3 | -3 | -1 | 0 | 2.6 + seq | path_seq | start_vid | end_vid | node | edge | cost | agg_cost +-----+----------+-----------+---------+------+------+------+---------- + 1 | 1 | -1 | 10 | -1 | 1 | 0.4 | 0 + 2 | 2 | -1 | 10 | 5 | 1 | 1 | 0.4 + 3 | 3 | -1 | 10 | 6 | 4 | 0.7 | 1.4 + 4 | 4 | -1 | 10 | -6 | 4 | 0.3 | 2.1 + 5 | 5 | -1 | 10 | 7 | 8 | 1 | 2.4 + 6 | 6 | -1 | 10 | 11 | 9 | 1 | 3.4 + 7 | 7 | -1 | 10 | 16 | 15 | 0.4 | 4.4 + 8 | 8 | -1 | 10 | -2 | 15 | 0.6 | 4.8 + 9 | 9 | -1 | 10 | 17 | 15 | 1 | 5.4 + 10 | 10 | -1 | 10 | 16 | 16 | 1 | 6.4 + 11 | 11 | -1 | 10 | 15 | 3 | 1 | 7.4 + 12 | 12 | -1 | 10 | 10 | -1 | 0 | 8.4 + 13 | 1 | 6 | -3 | 6 | 4 | 0.7 | 0 + 14 | 2 | 6 | -3 | -6 | 4 | 0.3 | 0.7 + 15 | 3 | 6 | -3 | 7 | 10 | 1 | 1 + 16 | 4 | 6 | -3 | 8 | 12 | 0.6 | 2 + 17 | 5 | 6 | -3 | -3 | -1 | 0 | 2.6 (17 rows) /* --q1 */ @@ -172,32 +172,32 @@ SELECT * FROM pgr_trsp_withPoints( ARRAY[-1, 6], ARRAY[-3, 1], directed => false, details => true); - seq | path_id | path_seq | start_vid | end_vid | node | edge | cost | agg_cost ------+---------+----------+-----------+---------+------+------+------+---------- - 1 | 1 | 1 | -1 | -3 | -1 | 1 | 0.6 | 0 - 2 | 1 | 2 | -1 | -3 | 6 | 4 | 0.7 | 0.6 - 3 | 1 | 3 | -1 | -3 | -6 | 4 | 0.3 | 1.3 - 4 | 1 | 4 | -1 | -3 | 7 | 10 | 1 | 1.6 - 5 | 1 | 5 | -1 | -3 | 8 | 12 | 0.6 | 2.6 - 6 | 1 | 6 | -1 | -3 | -3 | -1 | 0 | 3.2 - 7 | 2 | 1 | -1 | 1 | -1 | 1 | 0.6 | 0 - 8 | 2 | 2 | -1 | 1 | 6 | 4 | 0.7 | 0.6 - 9 | 2 | 3 | -1 | 1 | -6 | 4 | 0.3 | 1.3 - 10 | 2 | 4 | -1 | 1 | 7 | 7 | 1 | 1.6 - 11 | 2 | 5 | -1 | 1 | 3 | 6 | 0.7 | 2.6 - 12 | 2 | 6 | -1 | 1 | -4 | 6 | 0.3 | 3.3 - 13 | 2 | 7 | -1 | 1 | 1 | -1 | 0 | 3.6 - 14 | 3 | 1 | 6 | -3 | 6 | 4 | 0.7 | 0 - 15 | 3 | 2 | 6 | -3 | -6 | 4 | 0.3 | 0.7 - 16 | 3 | 3 | 6 | -3 | 7 | 10 | 1 | 1 - 17 | 3 | 4 | 6 | -3 | 8 | 12 | 0.6 | 2 - 18 | 3 | 5 | 6 | -3 | -3 | -1 | 0 | 2.6 - 19 | 4 | 1 | 6 | 1 | 6 | 4 | 0.7 | 0 - 20 | 4 | 2 | 6 | 1 | -6 | 4 | 0.3 | 0.7 - 21 | 4 | 3 | 6 | 1 | 7 | 7 | 1 | 1 - 22 | 4 | 4 | 6 | 1 | 3 | 6 | 0.7 | 2 - 23 | 4 | 5 | 6 | 1 | -4 | 6 | 0.3 | 2.7 - 24 | 4 | 6 | 6 | 1 | 1 | -1 | 0 | 3 + seq | path_seq | start_vid | end_vid | node | edge | cost | agg_cost +-----+----------+-----------+---------+------+------+------+---------- + 1 | 1 | -1 | -3 | -1 | 1 | 0.6 | 0 + 2 | 2 | -1 | -3 | 6 | 4 | 0.7 | 0.6 + 3 | 3 | -1 | -3 | -6 | 4 | 0.3 | 1.3 + 4 | 4 | -1 | -3 | 7 | 10 | 1 | 1.6 + 5 | 5 | -1 | -3 | 8 | 12 | 0.6 | 2.6 + 6 | 6 | -1 | -3 | -3 | -1 | 0 | 3.2 + 7 | 1 | -1 | 1 | -1 | 1 | 0.6 | 0 + 8 | 2 | -1 | 1 | 6 | 4 | 0.7 | 0.6 + 9 | 3 | -1 | 1 | -6 | 4 | 0.3 | 1.3 + 10 | 4 | -1 | 1 | 7 | 7 | 1 | 1.6 + 11 | 5 | -1 | 1 | 3 | 6 | 0.7 | 2.6 + 12 | 6 | -1 | 1 | -4 | 6 | 0.3 | 3.3 + 13 | 7 | -1 | 1 | 1 | -1 | 0 | 3.6 + 14 | 1 | 6 | -3 | 6 | 4 | 0.7 | 0 + 15 | 2 | 6 | -3 | -6 | 4 | 0.3 | 0.7 + 16 | 3 | 6 | -3 | 7 | 10 | 1 | 1 + 17 | 4 | 6 | -3 | 8 | 12 | 0.6 | 2 + 18 | 5 | 6 | -3 | -3 | -1 | 0 | 2.6 + 19 | 1 | 6 | 1 | 6 | 4 | 0.7 | 0 + 20 | 2 | 6 | 1 | -6 | 4 | 0.3 | 0.7 + 21 | 3 | 6 | 1 | 7 | 7 | 1 | 1 + 22 | 4 | 6 | 1 | 3 | 6 | 0.7 | 2 + 23 | 5 | 6 | 1 | -4 | 6 | 0.3 | 2.7 + 24 | 6 | 6 | 1 | 1 | -1 | 0 | 3 (24 rows) /* --q3 */ @@ -212,23 +212,23 @@ SELECT * FROM pgr_trsp_withPoints( $p$, 1, ARRAY[-1, -2], driving_side => 'r'); - seq | path_id | path_seq | start_vid | end_vid | node | edge | cost | agg_cost ------+---------+----------+-----------+---------+------+------+------+---------- - 1 | 1 | 1 | 1 | -2 | 1 | 6 | 1 | 0 - 2 | 1 | 2 | 1 | -2 | 3 | 7 | 1 | 1 - 3 | 1 | 3 | 1 | -2 | 7 | 8 | 0.9 | 2 - 4 | 1 | 4 | 1 | -2 | -2 | -1 | 0 | 2.9 - 5 | 2 | 1 | 1 | -1 | 1 | 6 | 1 | 0 - 6 | 2 | 2 | 1 | -1 | 3 | 7 | 1 | 1 - 7 | 2 | 3 | 1 | -1 | 7 | 8 | 2 | 2 - 8 | 2 | 4 | 1 | -1 | 7 | 10 | 1 | 4 - 9 | 2 | 5 | 1 | -1 | 8 | 12 | 1 | 5 - 10 | 2 | 6 | 1 | -1 | 12 | 13 | 1 | 6 - 11 | 2 | 7 | 1 | -1 | 17 | 15 | 1 | 7 - 12 | 2 | 8 | 1 | -1 | 16 | 16 | 1 | 8 - 13 | 2 | 9 | 1 | -1 | 15 | 3 | 1 | 9 - 14 | 2 | 10 | 1 | -1 | 10 | 5 | 0.8 | 10 - 15 | 2 | 11 | 1 | -1 | -1 | -1 | 0 | 10.8 + seq | path_seq | start_vid | end_vid | node | edge | cost | agg_cost +-----+----------+-----------+---------+------+------+------+---------- + 1 | 1 | 1 | -2 | 1 | 6 | 1 | 0 + 2 | 2 | 1 | -2 | 3 | 7 | 1 | 1 + 3 | 3 | 1 | -2 | 7 | 8 | 0.9 | 2 + 4 | 4 | 1 | -2 | -2 | -1 | 0 | 2.9 + 5 | 1 | 1 | -1 | 1 | 6 | 1 | 0 + 6 | 2 | 1 | -1 | 3 | 7 | 1 | 1 + 7 | 3 | 1 | -1 | 7 | 8 | 2 | 2 + 8 | 4 | 1 | -1 | 7 | 10 | 1 | 4 + 9 | 5 | 1 | -1 | 8 | 12 | 1 | 5 + 10 | 6 | 1 | -1 | 12 | 13 | 1 | 6 + 11 | 7 | 1 | -1 | 17 | 15 | 1 | 7 + 12 | 8 | 1 | -1 | 16 | 16 | 1 | 8 + 13 | 9 | 1 | -1 | 15 | 3 | 1 | 9 + 14 | 10 | 1 | -1 | 10 | 5 | 0.8 | 10 + 15 | 11 | 1 | -1 | -1 | -1 | 0 | 10.8 (15 rows) /* -- q4 */ diff --git a/sql/trsp/_trsp.sql b/sql/trsp/_trsp.sql index 962a8ecdc87..31e1bf13077 100644 --- a/sql/trsp/_trsp.sql +++ b/sql/trsp/_trsp.sql @@ -64,7 +64,6 @@ CREATE FUNCTION _v4trsp( directed BOOLEAN DEFAULT true, OUT seq INTEGER, - OUT path_id INTEGER, OUT path_seq INTEGER, OUT start_vid BIGINT, OUT end_vid BIGINT, @@ -84,7 +83,6 @@ CREATE FUNCTION _v4trsp( directed BOOLEAN DEFAULT true, OUT seq INTEGER, - OUT path_id INTEGER, OUT path_seq INTEGER, OUT start_vid BIGINT, OUT end_vid BIGINT, diff --git a/sql/trsp/_trsp_withPoints.sql b/sql/trsp/_trsp_withPoints.sql index 5bab47dfd94..21c71ad27a3 100644 --- a/sql/trsp/_trsp_withPoints.sql +++ b/sql/trsp/_trsp_withPoints.sql @@ -37,7 +37,6 @@ CREATE FUNCTION _pgr_trsp_withPoints( details BOOLEAN, OUT seq INTEGER, - OUT path_id INTEGER, OUT path_seq INTEGER, OUT departure BIGINT, OUT end_vid BIGINT, @@ -62,7 +61,6 @@ CREATE FUNCTION _pgr_trsp_withPoints( details BOOLEAN, OUT seq INTEGER, - OUT path_id INTEGER, OUT path_seq INTEGER, OUT departure BIGINT, OUT end_vid BIGINT, diff --git a/sql/trsp/trsp.sql b/sql/trsp/trsp.sql index 74ba9360561..9b379aa1cc3 100644 --- a/sql/trsp/trsp.sql +++ b/sql/trsp/trsp.sql @@ -35,7 +35,6 @@ CREATE FUNCTION pgr_trsp( directed BOOLEAN DEFAULT true, OUT seq INTEGER, - OUT path_id INTEGER, OUT path_seq INTEGER, OUT start_vid BIGINT, OUT end_vid BIGINT, @@ -69,7 +68,6 @@ CREATE FUNCTION pgr_trsp( directed BOOLEAN DEFAULT true, OUT seq INTEGER, - OUT path_id INTEGER, OUT path_seq INTEGER, OUT start_vid BIGINT, OUT end_vid BIGINT, @@ -101,7 +99,6 @@ CREATE FUNCTION pgr_trsp( directed BOOLEAN DEFAULT true, OUT seq INTEGER, - OUT path_id INTEGER, OUT path_seq INTEGER, OUT start_vid BIGINT, OUT end_vid BIGINT, @@ -133,7 +130,6 @@ CREATE FUNCTION pgr_trsp( directed BOOLEAN DEFAULT true, OUT seq INTEGER, - OUT path_id INTEGER, OUT path_seq INTEGER, OUT start_vid BIGINT, OUT end_vid BIGINT, @@ -164,7 +160,6 @@ CREATE FUNCTION pgr_trsp( directed BOOLEAN DEFAULT true, OUT seq INTEGER, - OUT path_id INTEGER, OUT path_seq INTEGER, OUT start_vid BIGINT, OUT end_vid BIGINT, diff --git a/sql/trsp/trsp_withPoints.sql b/sql/trsp/trsp_withPoints.sql index 15b1d299820..8649ca00fbb 100644 --- a/sql/trsp/trsp_withPoints.sql +++ b/sql/trsp/trsp_withPoints.sql @@ -38,7 +38,6 @@ CREATE FUNCTION pgr_trsp_withPoints( details BOOLEAN DEFAULT false, OUT seq INTEGER, - OUT path_id INTEGER, OUT path_seq INTEGER, OUT start_vid BIGINT, OUT end_vid BIGINT, @@ -74,7 +73,6 @@ CREATE FUNCTION pgr_trsp_withPoints( details BOOLEAN DEFAULT false, OUT seq INTEGER, - OUT path_id INTEGER, OUT path_seq INTEGER, OUT start_vid BIGINT, OUT end_vid BIGINT, @@ -109,7 +107,6 @@ CREATE FUNCTION pgr_trsp_withPoints( details BOOLEAN DEFAULT false, OUT seq INTEGER, - OUT path_id INTEGER, OUT path_seq INTEGER, OUT start_vid BIGINT, OUT end_vid BIGINT, @@ -144,7 +141,6 @@ CREATE FUNCTION pgr_trsp_withPoints( details BOOLEAN DEFAULT false, OUT seq INTEGER, - OUT path_id INTEGER, OUT path_seq INTEGER, OUT start_vid BIGINT, OUT end_vid BIGINT, @@ -179,7 +175,6 @@ CREATE FUNCTION pgr_trsp_withPoints( details BOOLEAN DEFAULT false, OUT seq INTEGER, - OUT path_id INTEGER, OUT path_seq INTEGER, OUT start_vid BIGINT, OUT end_vid BIGINT, diff --git a/src/trsp/new_trsp.c b/src/trsp/new_trsp.c index 8a403eee318..16402f42241 100644 --- a/src/trsp/new_trsp.c +++ b/src/trsp/new_trsp.c @@ -201,7 +201,7 @@ _v4trsp(PG_FUNCTION_ARGS) { bool* nulls; size_t call_cntr = funcctx->call_cntr; - size_t numb = 9; + size_t numb = 8; values = palloc(numb * sizeof(Datum)); nulls = palloc(numb * sizeof(bool)); @@ -214,14 +214,13 @@ _v4trsp(PG_FUNCTION_ARGS) { path_id += result_tuples[call_cntr].seq == 1? 1 : 0; values[0] = Int32GetDatum(call_cntr + 1); - values[1] = Int32GetDatum(path_id); - values[2] = Int32GetDatum(result_tuples[call_cntr].seq); - values[3] = Int64GetDatum(result_tuples[call_cntr].start_id); - values[4] = Int64GetDatum(result_tuples[call_cntr].end_id); - values[5] = Int64GetDatum(result_tuples[call_cntr].node); - values[6] = Int64GetDatum(result_tuples[call_cntr].edge); - values[7] = Float8GetDatum(result_tuples[call_cntr].cost); - values[8] = Float8GetDatum(result_tuples[call_cntr].agg_cost); + values[1] = Int32GetDatum(result_tuples[call_cntr].seq); + values[2] = Int64GetDatum(result_tuples[call_cntr].start_id); + values[3] = Int64GetDatum(result_tuples[call_cntr].end_id); + values[4] = Int64GetDatum(result_tuples[call_cntr].node); + values[5] = Int64GetDatum(result_tuples[call_cntr].edge); + values[6] = Float8GetDatum(result_tuples[call_cntr].cost); + values[7] = Float8GetDatum(result_tuples[call_cntr].agg_cost); result_tuples[call_cntr].seq = path_id; diff --git a/src/trsp/trsp_withPoints.c b/src/trsp/trsp_withPoints.c index 767d2c1d89a..35614a23acb 100644 --- a/src/trsp/trsp_withPoints.c +++ b/src/trsp/trsp_withPoints.c @@ -260,7 +260,7 @@ _pgr_trsp_withpoints(PG_FUNCTION_ARGS) { bool* nulls; size_t call_cntr = funcctx->call_cntr; - size_t numb = 9; + size_t numb = 8; values = palloc(numb * sizeof(Datum)); nulls = palloc(numb * sizeof(bool)); @@ -273,14 +273,13 @@ _pgr_trsp_withpoints(PG_FUNCTION_ARGS) { path_id += result_tuples[call_cntr].seq == 1? 1 : 0; values[0] = Int32GetDatum(call_cntr + 1); - values[1] = Int32GetDatum(path_id); - values[2] = Int32GetDatum(result_tuples[call_cntr].seq); - values[3] = Int64GetDatum(result_tuples[call_cntr].start_id); - values[4] = Int64GetDatum(result_tuples[call_cntr].end_id); - values[5] = Int64GetDatum(result_tuples[call_cntr].node); - values[6] = Int64GetDatum(result_tuples[call_cntr].edge); - values[7] = Float8GetDatum(result_tuples[call_cntr].cost); - values[8] = Float8GetDatum(result_tuples[call_cntr].agg_cost); + values[1] = Int32GetDatum(result_tuples[call_cntr].seq); + values[2] = Int64GetDatum(result_tuples[call_cntr].start_id); + values[3] = Int64GetDatum(result_tuples[call_cntr].end_id); + values[4] = Int64GetDatum(result_tuples[call_cntr].node); + values[5] = Int64GetDatum(result_tuples[call_cntr].edge); + values[6] = Float8GetDatum(result_tuples[call_cntr].cost); + values[7] = Float8GetDatum(result_tuples[call_cntr].agg_cost); result_tuples[call_cntr].seq = path_id; diff --git a/tools/testers/types_check.sql b/tools/testers/types_check.sql index 00614073394..6332b1b621f 100644 --- a/tools/testers/types_check.sql +++ b/tools/testers/types_check.sql @@ -12,8 +12,8 @@ DECLARE return_params_names TEXT[]; return_params_numbers OID[]; - return_params_names_start TEXT[] = ARRAY['seq','path_id','path_seq']; - return_params_numbers_start OID[] = ARRAY[23,23,23]; + return_params_names_start TEXT[] = ARRAY['seq','path_seq']; + return_params_numbers_start OID[] = ARRAY[23,23]; return_params_names_end TEXT[] = ARRAY['node','edge','cost','agg_cost']; return_params_numbers_end OID[] = ARRAY[20,20,701,701]; @@ -22,7 +22,7 @@ DECLARE startend_v TEXT[] = ARRAY[start_v,end_v]; BEGIN - IF fn IN ('pgr_trsp', 'pgr_trsp_withpoints', 'pgr_withpointsvia') AND NOT min_version('3.4.0') THEN + IF fn IN ('pgr_trsp', 'pgr_trsp_withpoints') AND NOT min_version('3.4.0') THEN RETURN QUERY SELECT skip(1, 'Signature added on 3.4.0'); RETURN; END IF;