[postgis-devel] Cast GeoJSON to geometry like with WKT

rmrodriguez at carto.com rmrodriguez at carto.com
Mon Mar 30 08:56:22 PDT 2020


I've been bitten by this today. This code used to work in Postgis 2.x:
```
SELECT (data->0->>'value')::Geometry
```
But it now requires to be called as:
```
ST_GeomFromGeoJSON(data->0->>'value')
```

So I wouldn't be opposed to backporting this to 3.0 if it were to be
implemented.

-- 
Raúl Marín Rodríguez
carto.com


More information about the postgis-devel mailing list