https://gitee.com/zjko_0/pg-coordtransform.git
PG 各类纠偏函数
|
|
%!s(int64=6) %!d(string=hai) anos | |
|---|---|---|
| example | %!s(int64=6) %!d(string=hai) anos | |
| src | %!s(int64=6) %!d(string=hai) anos | |
| LICENSE | %!s(int64=6) %!d(string=hai) anos | |
| README.md | %!s(int64=6) %!d(string=hai) anos | |
| geoc_gcj02_wgs84.sql | %!s(int64=6) %!d(string=hai) anos |
基于PostgreSQL+PostGIS的坐标转换函数,支持点、线、面的WGS84与GCJ02坐标互转
GCJ02转WGS84
select geoc_gcj02towgs84(geom) from test_table
WGS84转GCJ02
select geoc_wgs84togcj02(geom) from test_table
PostgreSQL安装PostGIS扩展
复制geoc_gcj02_wgs84.sql中代码,在数据库执行