1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
|
BEGIN;
BEGIN
SET client_min_messages TO NOTICE;
SET
/* :file: This file is part of the pgRouting project.
:copyright: Copyright (c) 2016-2026 pgRouting developers
:license: Creative Commons Attribution-Share Alike 3.0 https://creativecommons.org/licenses/by-sa/3.0 */
/* -- q1 */
SELECT edge, cost FROM pgr_prim(
'SELECT id, source, target, cost, reverse_cost
FROM edges WHERE id < 14'
) ORDER BY edge;
edge | cost
------+------
1 | 1
2 | 1
3 | 1
4 | 1
6 | 1
7 | 1
8 | 1
9 | 1
10 | 1
12 | 1
13 | 1
(11 rows)
/* -- q2 */
ROLLBACK;
ROLLBACK
|