I have hundreds of CSV files in one folder that I would like to convert to shapefile with ogr2ogr, but I am not able to get the desired EPSG:3067 - I get EPSG:3047 instead.
First, I used the following command to convert CSV to shapefile with no luck (the shapefile was EPSG:3047):
for /R %f in (*.csv) do ogr2ogr -s_srs EPSG:4326 -t_srs EPSG:3067 -oo X_POSSIBLE_NAMES=Lon* -oo Y_POSSIBLE_NAMES=Lat* -f "ESRI Shapefile" "%~dpnf.shp" %f
Then I used the second command and tried to reproject to EPSG:3067 with the following command, but still the result was EPSG:3047:
for /R %f in (*.shp) do ogr2ogr -a_srs EPSG:3067 -f "ESRI Shapefile" "%~dpnf_newepsg.shp" %f
The only way I can make it work is to manually open the CSV in QGis, file by file, and then save them as shapefile with EPSG:3067.
Am I missing something here?
EDIT
Using command ogrinfo -al -so test.shp
on newly created shapefile returns the following information:
Layer SRS WKT:
PROJCS["ETRS89_TM35FIN_E_N",
GEOGCS["GCS_ETRS_1989",
DATUM["European_Terrestrial_Reference_System_1989",
SPHEROID["GRS_1980",6378137,298.257222101]],
PRIMEM["Greenwich",0],
UNIT["Degree",0.017453292519943295]],
PROJECTION["Transverse_Mercator"],
PARAMETER["latitude_of_origin",0],
PARAMETER["central_meridian",27],
PARAMETER["scale_factor",0.9996],
PARAMETER["false_easting",500000],
PARAMETER["false_northing",0],
UNIT["Meter",1]]
According to this it should be EPSG:3067..? But in QGis it still appears as EPSG:3047.
ogrinfo -al -so xxx_newepsg.shp
?-t_srs EPSG:3067
to reproject in the second line.-a_srs
only assigns a CRS, and does no recomputation of coordinates. BTW I don't see EPSG:3047 in your commands.