GeoJSON 规范展示,
{
"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [125.6, 10.1]
},
"properties": {
"name": "Dinagat Islands"
}
}
Run Code Online (Sandbox Code Playgroud)
但是当我把它包装在一个调用中时ST_GeomFromGeoJSON
,像这样,
SELECT ST_GeomFromGeoJSON($${
"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [125.6, 10.1]
},
"properties": {
"name": "Dinagat Islands"
}
}$$);
Run Code Online (Sandbox Code Playgroud)
我得到错误,
错误:无效的 GeoJson 表示