postgresql安装geom地理信息字段
程序员文章站
2022-04-15 12:42:09
...
确保数据库已安装postgis,然后执行
CREATE EXTENSION postgis
java中的写法(使用jpa),自动生成表字段,配置自己配
@Column(name = "the_geom",columnDefinition ="geometry(Geometry)")
private MultiPolygon polygon;
@Column(name = "the_geom",columnDefinition ="geometry(Geometry)")
private Point polygon;