[Gdal-dev] ogr and utf-8 encoding

Frank Warmerdam warmerdam at pobox.com
Fri Oct 5 14:40:30 EDT 2007


Roger André wrote:
> Hi all,
> 
> I'm converting a CSV file that contains names which are utf-8 encoded
> into a shapefile with ogr in Python.  It appears from my research that
> there is currently no way to specify an encoding type with ogr for the
> fields in the target shapefile.  I see that there is an RFC to
> "enhance" gdal/ogr so that it can respect input encoding, but am not
> sure if I've missed another obvious way to preserve the diacritics in
> my input data.
> 
> Could someone please let me know if, A) there is a way to preserve
> unicode encoding from source and pass it into a new shapefile, B) what
> the status is on RFC-5, "Unicode support in GDAL", and when this
> functionality might be available.

Roger,

My understanding is that no work on utf-8 or RFC-5 has been done yet.
Currently there is no mechanism to set the code page for shapefiles nor for
identifying the code page from csv files.

Best regards,
-- 
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | President OSGeo, http://osgeo.org




More information about the Gdal-dev mailing list