BEGIN;
BEGIN
SET client_min_messages TO NOTICE;
SET
-- q1
SELECT * FROM pgr_bdDijkstraCost(
    'SELECT id, source, target, cost, reverse_cost FROM edge_table',
    2, 3
);
 start_vid | end_vid | agg_cost 
-----------+---------+----------
         2 |       3 |        5
(1 row)

-- q2
SELECT * FROM pgr_bdDijkstraCost(
    'SELECT id, source, target, cost, reverse_cost FROM edge_table',
    2, 3,
    false
);
 start_vid | end_vid | agg_cost 
-----------+---------+----------
         2 |       3 |        1
(1 row)

-- q3
SELECT * FROM pgr_bdDijkstraCost(
    'SELECT id, source, target, cost, reverse_cost FROM edge_table',
    2, ARRAY[3, 11]);
 start_vid | end_vid | agg_cost 
-----------+---------+----------
         2 |       3 |        5
         2 |      11 |        3
(2 rows)

-- q4
SELECT * FROM pgr_bdDijkstraCost(
    'SELECT id, source, target, cost, reverse_cost FROM edge_table',
    ARRAY[2, 7], 3);
 start_vid | end_vid | agg_cost 
-----------+---------+----------
         2 |       3 |        5
         7 |       3 |        6
(2 rows)

-- q5
SELECT * FROM pgr_bdDijkstraCost(
    'SELECT id, source, target, cost, reverse_cost FROM edge_table',
    ARRAY[2, 7], ARRAY[3, 11]);
 start_vid | end_vid | agg_cost 
-----------+---------+----------
         2 |       3 |        5
         2 |      11 |        3
         7 |       3 |        6
         7 |      11 |        4
(4 rows)

-- q6
ROLLBACK;
ROLLBACK
