Hot answers tagged

4

You must run two separate commands ogr2ogr -append --config OGR_TRUNCATE YES --config PG_USE_COPY YES \ -nlt PROMOTE_TO_MULTI \ -nln vector_data.el_lines \ -f "PostgreSQL" PG:"host=localhost user=user dbname=my_database" \ -a_srs EPSG:4326 "${gpkgdir}/multiple_vector_data.gpkg" "el_lines" ogr2ogr -append --config OGR_TRUNCATE YES --config PG_USE_COPY YES \...


3

Read https://gdal.org/drivers/vector/pg.html Configuration Options OGR_TRUNCATE: (GDAL >= 1.11) If set to “YES”, the content of the table will be first erased with the SQL TRUNCATE command before inserting the first feature. This is an alternative to using the -overwrite flag of ogr2ogr, that avoids views based on the table to be ...


1

Based on the ouput from vcpkg when installing any new package: Computing installation plan... The following packages will be built and installed: zlib[core]:x64-windows Starting package 1/1: zlib:x64-windows Building package zlib[core]:x64-windows... -- Downloading http://www.zlib.net/zlib-1.2.11.tar.gz... -- Extracting source D:/Dev/vcpkg/downloads/...


1

NetCDF driver is documented in https://gdal.org/drivers/raster/netcdf.html Creation Issues This driver supports creation of NetCDF file following the CF-1 convention. You may create set of 2D datasets. Each variable array is named Band1, Band2, … BandN. Each band will have metadata tied to it giving a short description of the data it contains. ...


1

Thanks @ustroetz for your excellent answer, it really helped me a lot. I will share an adjustment and extra step I implemented to remove the unsightly loops that appear as a consequence of the process. Note that this only works if your network is tree-like, which fortunately for my use case, mine always are. I introduce geopandas and networkx for this ...


Only top voted, non community-wiki answers of a minimum length are eligible