[gdal-dev] Source SRS not honoured if shapefile .prj file exists

Andre Joost andre+joost at nurfuerspam.de
Thu Jun 6 21:10:57 PDT 2013


Am 07.06.2013 01:42, schrieb Jukka Rahkonen:
> Hi,
>
> I received a shapefile with a non-perfect .prj file which does not advertise
> that the coordinate system is Finnish KKJ (EPSG:2393) which needs +towgs84
> parameters. I knew that GDAL 1.10 finally comes with correct parameters and
> thought that problem could be solved easily by adding parameter "-s_srs
> epsg:2393" into ogr2ogr command. However, GDAL does not honour the parameter
> if the .prj still exists in the shapefile directory. Only after deleting the
> .prj file I got the correct result. I think that the correct behaviour would
> be the opposite and take -s_srs instead of .prj if both are available.
>
> Tested with GDAL 1.10.0, released 2013/04/13 and my command was
> ogr2ogr -f KML -s_srs epsg:2393 -t_srs epsg:4326 test4.kml test_region.shp
>


Can you test with the full proj string as well? I discovered some 
differences between supplying EPSG code and full proj string.

Greetings,
André Joost




More information about the gdal-dev mailing list