PostgreSQL 版本 10 是否支持 pgRouting 版本 2.6?
Does PostgreSQL version 10 support pgRouting version 2.6?
我通过 brew 安装了 pgRouting 版本 2.6,我有 PostgreSQL 版本 10.4。现在我有一个问题:这个 PostgreSQL 版本是否支持 pgRouting 扩展?因为我每次查询:
SELECT *
FROM shortest_path('SELECT gid AS id, start_id::int4 AS source, end_id::int4 AS target, cost_length::float8 AS cost FROM network', 1, 135, false, false);
此查询失败并给出错误信息:
ERROR: function shortest_path(unknown, integer, integer, boolean, boolean) does not exist
LINE 1: SELECT * FROM shortest_path('
^
HINT: No function matches the given name and argument types. You might need to add explicit type casts.
Query failed
自 2.0 版以来,该功能已过时并从核心中删除;您想要使用 current collection 路由功能之一,例如
SELECT *
FROM pgr_Dijkstra(
'SELECT gid AS id,
start_id::int4 AS source,
end_id::int4 AS target,
cost_length::float8 AS cost
FROM network',
1,
135,
false
);
我通过 brew 安装了 pgRouting 版本 2.6,我有 PostgreSQL 版本 10.4。现在我有一个问题:这个 PostgreSQL 版本是否支持 pgRouting 扩展?因为我每次查询:
SELECT *
FROM shortest_path('SELECT gid AS id, start_id::int4 AS source, end_id::int4 AS target, cost_length::float8 AS cost FROM network', 1, 135, false, false);
此查询失败并给出错误信息:
ERROR: function shortest_path(unknown, integer, integer, boolean, boolean) does not exist
LINE 1: SELECT * FROM shortest_path('
^
HINT: No function matches the given name and argument types. You might need to add explicit type casts.
Query failed
自 2.0 版以来,该功能已过时并从核心中删除;您想要使用 current collection 路由功能之一,例如
SELECT *
FROM pgr_Dijkstra(
'SELECT gid AS id,
start_id::int4 AS source,
end_id::int4 AS target,
cost_length::float8 AS cost
FROM network',
1,
135,
false
);