I have been using a Geoserver for years with my developers querying it using lat/long to get US parcel boundaries from a SQL Server store. I got a dataset with UK parcel boundaries but it's in EPSG:27700 (UTM). I can query it fine using UTM values but I need to use lat/long and I'm not sure what the trick is. The Geoserver lists the native SRS as EPSG:4326 for some odd reason. I think it should say EPSG:27700 for native and I want EPSG:4326 for declared, with either "reproject native to declared" or "force declared." Any guesses as to what I'm doing wrong?

closed as unclear what you're asking by Ian Turton Oct 10 '17 at 7:36

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • 27700 is OSGB not UTM - are your coordinates large numbers or small numbers, large is 27700 and small will be 4326 – Ian Turton Oct 9 '17 at 8:23
  • The coordinates in the data I was given look like UTM (my mistake, newbie here). Here's an example in text form: POLYGON ((360230.846 176528.235, 360233.993 176532.379, 360232.85000000003 176533.45, 360215.10000000003 176548.2, 360206.8 176555.1, 360202.15 176558.9, 360198.8 176554.80000000002, 360203.4 176550.95, 360209.45 176545.9, 360229.60000000003 176529.2, 360230.5 176528.55000000002, 360230.846 176528.235)) – influent Oct 9 '17 at 16:02
  • This link makes it sound like I should use the "Petroleum conversion" to change the values to WGS-84: communityhub.esriuk.com/geoxchange/2012/3/26/… – influent Oct 9 '17 at 16:12
  • Just set epsg 27700 as declared and geoserver will take care of the rest – Ian Turton Oct 9 '17 at 16:15
  • But I need to pass in lat/long. I've tried that and it doesn't render the polygons, unless I use the big decimal values instead (what I thought was UTM). – influent Oct 9 '17 at 20:30

This could be a case of geoserver can't find implicitly what's an EPSG so it's setting 4326 - try to define it explicitly. If you're using shapefiles create .prj file, if PostGIS convert datatype for column into geometry(Geometry,27700)...

It's just a guess... not enough details in question :)

  • I'm using a SQL Server database. When I use Stsrid it says it's 27700. – influent Oct 8 '17 at 14:25
  • OK, but sometimes that's not enough for geoserver... what is a ddl for this table? Maybe try "alter table table_name alter geom_column column type geometry(Geometry,27700);" – Jendrusk Oct 8 '17 at 18:20

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