0

2022 layer upload shows this error any ideas?

Caused by: org.opengis.referencing.NoSuchAuthorityCodeException: No code "EPSG:900914" from authority "European Petroleum Survey Group" found for object of type "IdentifiedObject".

Adding more deatils from the duplicate ticket:

We are using GDAL ogr2pgr commpand to read shapefiles and load into a PostGIS DB.

The prj file associated with the shape file is in EPSG4326 WGS-84

GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]]

When we use GDAL 3.0.4, released 2020/01/28 with the shapefile with prj the SRID in the PostGIS DB is EPSG 4326 and is published via the GeoServer.

But When we use GDAL 3.4.1, released 2021/12/27 with the same shapefile with prj the SRID in the PostGIS DB is EPS 900914 (Google I guess) I am unable to publish it via the GeoServer.

What is the issue here? Why is the SRID different in GDAl 3.0.4 and GDAL 3.4.1

The PostGIS version is 3.2 USE_GEOS=1 USE_PROJ=1 USE_STATS=1 The PostgreSQL version is 14.2 (Ubuntu 14.2-1.pgdg20.04+1)

2
  • 1
    Welcome to GIS.SE. If possible, please open your file(raster/vector) in QGIS, check its projection, and if it is missing, add the projection and save your data set. Again open the same file, if is it working fine then its good to publish it on Geoserver
    – Sunil
    Sep 21, 2022 at 6:58
  • does gis.stackexchange.com/questions/439509/… help?
    – Ian Turton
    Sep 21, 2022 at 7:34

2 Answers 2

0

In QGIS the project shows just fine as EPSG 4326 and that is right. Somehow the GDAL version 3.4 seems to read this as 900914 and that is not publishable via the Geoserver.

enter image description here

0

For some reason that GDAL version considers that the .prj file defines a different CRS than EPSG:4326. Or at least somehow different to the one that is stored into PostGIS with code 4326.

As a workaround I would save the data into PostGIS by running ogr2ogr with option -a_srs epsg:4326 https://gdal.org/programs/ogr2ogr.html#cmdoption-ogr2ogr-a_srs

Assign an output SRS, but without reprojecting (use -t_srs to reproject)

The coordinate reference systems that can be passed are anything supported by the OGRSpatialReference::SetFromUserInput() call, which includes EPSG Projected, Geographic or Compound CRS (i.e. EPSG:4296), a well known text (WKT) CRS definition, PROJ.4 declarations, or the name of a .prj file containing a WKT CRS definition.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.