gpt4 book ai didi

postgresql - 如何将 OSM 导出到包含所有城市和街道名称的数据库?

转载 作者:行者123 更新时间:2023-11-29 13:21:59 28 4
gpt4 key购买 nike

我下载了我所在县的 osm map 并创建了空间 pg 数据库。我使用以下命令通过 osm2pgrouting 导出的 Osm 文件:

osm2pgrouting -f myCity.osm -c mapconfig.xml -d postgis_db -U postgres -W postgres --addnodes --clean 

导出表后我有这个模式:

osm_node:
-node_id
-osm_id
-lon
-lat
-numofuse
-the_geom

osm_relations:
-relation_id
-type_id
-class_id
-name

osm_way_classes
-class_id
-type_id
-name
-priority
-default_max_speed

osm_way_tags
-class_id
-way_id

osm_way_types
-type_id
-name

pointcloud_formats
-pcid
-srid
-schema

relation_ways
-relation_id
-way_id
-type

spatial_ref_sys
-srid
-auth_name
-auth_srid
-srtext
-proj4text

ways
-gid
-class_id
-length
-length_m
-name
-source
-target
-x1
-y1
-x2
-y2
-cost
-reverse_cost
-cost_s
-reverse_cost_s
-rule
-one_way
-maxspeed_foward
-maxspeed_backward
-osm_id
-source_osm
-target_osm
-priority
-the_geom

ways_vertices_pgr
-id
-osm_id
-cnt
-cnt
-chk
-ein
-eout
-lon
-lat
-the_geom

你能告诉我我哪里做错了吗?如何将 osm 文件导入包含城市和街道等所有节点的数据库?感谢您的回答。

最佳答案

osm2pgrouting 不导入门牌号、城市等。如上所述,它导入计算路线所需的数据。还有其他工具也可以将 OSM 数据导入 postGIS。请参阅:http://wiki.openstreetmap.org/wiki/PostGIS

其中一些其他工具会导入更多数据和标签,但可能无法使表格适合路由。

关于postgresql - 如何将 OSM 导出到包含所有城市和街道名称的数据库?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40166693/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com