2
The ArcGIS Pro python environment doesn't include the GDAL/OGR commandline utilities, just the python bindings.
You can use gdal.VectorTranslate to do the same thing as ogr2ogr.
2
You can specify the name of the tale inside a Geopackage:
ogr2ogr -f "PostgreSQL" "PG:database" -t_srs EPSG:3035 -overwrite -lco \
GEOMETRY_NAME=geom -nln "corine.corine12_vec" \
U2018_CLC2012_V2020_20u1.gpkg NAME_OF_LAYER
So for example for the U2018_CLC2012_V2020_20u1 layer:
ogr2ogr -f "PostgreSQL" "PG:...
2
TL;DR
bash /path/to/shp2geojson.sh /path/to/input.shp /path/to/output-dir
shp2geojson.sh
#!/bin/bash
clear;
layername=$(ogrinfo -nogeomtype "$1" | grep "1:" | awk '{print $2}')
count=$(ogrinfo -so -ro "$1" "$layername" | grep "Feature Count:" | awk '{print $3}')
if [ -d $2 ]; then
echo "The ...
1
This is an addon for Apache Beam that can load and process GIS data on Google Dataflow: https://github.com/GoogleCloudPlatform/dataflow-geobeam.
It includes I/O connectors for GeoTiff, Shapefiles, and Geodatabases.
1
It may be hard to deal properly with that WFS server because it sends invalid data. You can make a test with a browser
https://georisques.gouv.fr/services?SERVICE=WFS&VERSION=2.0.0&REQUEST=GetFeature&TYPENAMES=ms:SSP_INSTR_GE&STARTINDEX=0&COUNT=8
The response even contains this message that is meant to be a hint for those who administrate ...
1
To change the type of a column, you need to use ALTER TABLE. Use NULLIF to convert empty strings into NULLs:
ALTER TABLE MyTable
ALTER COLUMN geom
SET DATA TYPE geometry(geometry, 27700) -- or geometry(point, 27700)
USING ST_SetSRID(ST_GeomFromText(NULLIF(geom, '')), 27700);
1
Where to find and how to install the `FileGDB' driver? Does it still exist?
You need to compile yourself gdal using a recipe like below (tested on Ubuntu 18.04, should not differ a lot for your OS target)
# Update install
sudo apt update && sudo apt upgrade
# Get deps to reuse deps instead of installing them by hand
sudo apt-get build-dep gdal-bin
#...
Only top voted, non community-wiki answers of a minimum length are eligible
Related Tags
ogr2ogr × 889gdal × 246
shapefile × 178
postgis × 158
geojson × 101
ogr × 92
qgis × 81
postgresql × 80
python × 61
kml × 51
coordinate-system × 48
sql × 43
file-geodatabase × 43
openstreetmap × 38
sqlite × 37
convert × 33
sql-server × 30
csv × 27
spatialite × 27
gml × 20
dxf × 19
geopackage × 17
sql-server-spatial × 17
export × 15
mapinfo × 15