[gdal-dev] Zip-Compressed GeoJSON Files?
Rahkonen Jukka
jukka.rahkonen at maanmittauslaitos.fi
Sun Feb 23 02:05:55 PST 2025
Hi,
I think this is documented in https://gdal.org/en/stable/user/virtual_file_systems.html#write-capabilities. At least after reading it I concluded that I must define both the zip file and the file to be inserted, and in that order.
ogr2ogr -f "geojson" /vsizip/output.zip/geojson test.shp
Test what I have
ogrinfo /vsizip/output.zip
INFO: Open of `/vsizip/output.zip'
using driver `GeoJSON' successful.
1: test (3D Multi Polygon)
-Jukka Rahkonen-
Lähettäjä: gdal-dev <gdal-dev-bounces at lists.osgeo.org> Puolesta Simon Eves via gdal-dev
Lähetetty: lauantai 22. helmikuuta 2025 3.31
Vastaanottaja: gdal dev <gdal-dev at lists.osgeo.org>
Aihe: Re: [gdal-dev] Zip-Compressed GeoJSON Files?
Same with 3.10.1.
On Fri, Feb 21, 2025 at 3:12 PM Simon Eves <simon.eves at heavy.ai<mailto:simon.eves at heavy.ai>> wrote:
Revisiting our geo export options after several years and hit something weird.
Testing with the command-line tools, this works...
ogr2ogr -f "geojson" /vsigzip//path/to/output.geojson.gz <input>
This does not...
ogr2ogr -f "geojson" /vsizip//path/to/output.geojson.zip <input>
It spits a ton of errors (attached) and while the zip file is created, it has no files in it.
Am I doing something silly, or is this a bug?
Does anyone really use or expect individually-zipped GeoJSON files anyway?
This is with GDAL 3.7.3. We are updating to 3.11 so I'll try that too.
--
Simon Eves
Senior Rendering Engineer
+1 (415) 902-1996
simon.eves at heavy.ai<mailto:simon.eves at heavy.ai>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20250223/43a61ce7/attachment.htm>
More information about the gdal-dev
mailing list