Opened 9 years ago
Closed 7 years ago
#6011 closed defect (fixed)
EPSG:31258 code not identified from Shapefile .prj
Reported by: | dcarrion | Owned by: | warmerdam |
---|---|---|---|
Priority: | normal | Milestone: | 2.3.0 |
Component: | default | Version: | unspecified |
Severity: | normal | Keywords: | |
Cc: |
Description
When trying to import the attached file, even though the EPSG:31258 (MGI / Austria GK M31) projection is correctly identified by orginfo, it only works alright with ogr2ogr if forced with -s_srs EPSG:31258 (tested up to r29424)
Change History (7)
comment:1 by , 9 years ago
comment:2 by , 9 years ago
Yes, known issue. Shapefile .prj files don't include the EPSG code, and there's nothing currently to easily re-identify it.
comment:3 by , 9 years ago
Summary: | EPSG:31258 is not correctly detected by ogr2ogr → EPSG:31258 code not identified from Shapefile .prj |
---|
follow-up: 5 comment:4 by , 9 years ago
And wouldn't it make sense to fail in that case instead of going ahead with an unknown projection? That way you could inform the user that she needs to specify a projection.
comment:5 by , 9 years ago
Replying to dcarrion:
And wouldn't it make sense to fail in that case instead of going ahead with an unknown projection? That way you could inform the user that she needs to specify a projection.
That's not possible to know, in the current state of the code, if the projection interpreted from the .prj file is complete or not. It is technically valid, "just" missing the TOWGS84 node. But we can only know that by trying to match with the EPSG database. Code improvement needed.
comment:6 by , 9 years ago
ok, got it. i'll take a look at the code and hopefully come back with some ideas. thanks a lot!
comment:7 by , 7 years ago
Milestone: | → 2.3.0 |
---|---|
Resolution: | → fixed |
Status: | new → closed |
Should be mostly solved with r40207. Duplicate of #4345
$ gdalsrsinfo -e ESRI::Tonnage.prj EPSG:31258 PROJ.4 : +proj=tmerc +lat_0=0 +lon_0=13.33333333333333 +k=1 +x_0=450000 +y_0=-5000000 +ellps=bessel +towgs84=577.326,90.129,463.919,5.137,1.474,5.297,2.4232 +units=m +no_defs OGC WKT : PROJCS["MGI / Austria GK M31", GEOGCS["MGI", DATUM["Militar_Geographische_Institute", SPHEROID["Bessel 1841",6377397.155,299.1528128, AUTHORITY["EPSG","7004"]], TOWGS84[577.326,90.129,463.919,5.137,1.474,5.297,2.4232], AUTHORITY["EPSG","6312"]], PRIMEM["Greenwich",0, AUTHORITY["EPSG","8901"]], UNIT["degree",0.0174532925199433, AUTHORITY["EPSG","9122"]], AUTHORITY["EPSG","4312"]], PROJECTION["Transverse_Mercator"], PARAMETER["latitude_of_origin",0], PARAMETER["central_meridian",13.33333333333333], PARAMETER["scale_factor",1], PARAMETER["false_easting",450000], PARAMETER["false_northing",-5000000], UNIT["metre",1, AUTHORITY["EPSG","9001"]], AUTHORITY["EPSG","31258"]]
Sorry, the file is too big to be attached. Please download from here: https://drive.google.com/file/d/0B8DYAZ9FReGfRG5WMWhldHdrbFk/view?usp=sharing