[gdal-dev] PGCLIENTENCODING in ogr2ogr (and QGIS)
matteo
matteo.ghetta at gmail.com
Fri Dec 3 05:55:04 PST 2021
Hi Rahkonen,
sorry for the delay. The command, built with Processing in QGIS using
the GdalUtils utility is at the end:
ogr2ogr -f PostgreSQL "PG:dbname='db' host=myhost port=myport
user='myuser' password='mypassword' sslmode=disable schemas=myschema"
shapefile.shp --config PG_USE_COPY YES -append -skipfailures -nlt
PROMOTE_TO_MULTI -doo PRELUDE_STATEMENTS="SET client_encoding TO LATIN1"
a small file can be found here:
https://faunalia.eu/~matteo/shapefile.zip
and yes. The database encoding is:
HOW SERVER_ENCODING;
server_encoding
-----------------
UTF8
(1 row)
while the encoding of the shapefile is ISO-8859-1
Thanks for any hint!
Matteo
More information about the gdal-dev
mailing list