I'm having this error, and I just don't know if it's an issue or something I'm doing wrong. When converting a GeoJSON file, generated by
ogr2ogr -f "GeoJSON" INPUT.json INPUT.shp
with the topojson module, and preserving the properties, some Spanish characters are not preserved:
topojson -p -o OUTPUT.json INPUT.json
For example: Castellón
from the INPUT.json file (checked, there are no erros in that file) ends like Castell�n
in the OUTPUT.json file. The properties are well preserved except for characters like á
, í
, ó
, etc. (common in Spanish).
I've tried adding --shapefile-encoding utf8
without success.
Well it's almost 1 year late but I'll lleave here my solution because probably more people will have this problem. Solved it in 2 steps:
--shapefile-encoding utf8
as Nacho did And all my beautiful accents and tildes are back