<br><font size=2 face="sans-serif">Hi,</font>
<br>
<br><font size=2 face="sans-serif">We have made the changes to remove the
explicit layer setProjection and allow each layer to inherit the projection
from its map. &nbsp;</font>
<br>
<br><font size=2 face="sans-serif">However for some vector layers we consistently
get: </font>
<br><font size=2 face="sans-serif">&quot;Layer must have an EPSG or AUTO
projection code (in its PROJECTION object or wms_srs metadata)&quot;</font>
<br>
<br><font size=2 face="sans-serif">A layer either works or does not work,
but 30% of our layers fail with this error. &nbsp;Also layers that work
or fail differ between environments.</font>
<br>
<br><font size=2 face="sans-serif">We don't use a map file for layer data
(just for mapObj config) as all of our layer configurations are stored
in a database. &nbsp;Our WMS_LAYERS table stores all of the data that you
would normally see within the LAYERS section of a mapfile.</font>
<br>
<br><font size=2 face="sans-serif">I have checked the PROJECTION setting
and for all layers it is set to &quot;init='epsg:27700'&quot;.</font>
<br>
<br><font size=2 face="sans-serif">Our code manually constructs mapObj
and layerObj objects taking the configuration from our config database.</font>
<br>
<br><font size=2 face="sans-serif">When our code constructs the layerObj
JNI objects it checks the PROJECTION value from the database and if the
DB value is the same as the mapObj projection then the code skips the layerObj.setProjection
because it assumes that the layer will inherit the projection from the
mapObj used in the constructor of the layerObj.</font>
<br>
<br><font size=2 face="sans-serif">None of the layers in the list are WMS
layers and the layers that fail are all going to our Oracle Spatial database.</font>
<br>
<br><font size=2 face="sans-serif">I have asked the database team to investigate
the differences between layers that work and fail in the same environment
and layers that work in one environment and fail in another. &nbsp;I have
inspected the development database and a I cannot see anything different
between a layer that works and one that does not.</font>
<br>
<br><font size=2 face="sans-serif">e.g. If I simulate the mapfile syntax
for our layers for the benefit of the email, if we had defined our layers
in the mapfile they would look like this:</font>
<br>
<br><font size=2 face="sans-serif">LAYER</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;NAME &nbsp;&quot;2001UrbanAreas(Census)&quot;</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;CONNECTION &quot;&lt;usr&gt;/&lt;pwd&gt;@SPR01&quot;</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;STATUS ON</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;TYPE POLYGON</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;DATA &quot;GEOMETRY FROM
OTHERAGENCIES.DCLG00000001 USING SRID 81989&quot;</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;MAXSCALE 99999999</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;MINSCALE 0</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;TRANSPARENCY 60</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;PROJECTION &quot;init=epsg:27700&quot;</font>
<br><font size=2 face="sans-serif">END</font>
<br>
<br><font size=2 face="sans-serif">LAYER</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;NAME &nbsp;&quot;EnglishHeritageRegions&quot;</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;CONNECTION &quot;&lt;usr&gt;/&lt;pwd&gt;@SPR01&quot;</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;STATUS ON</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;TYPE POLYGON</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;DATA &quot;GEOMETRY FROM
OTHERAGENCIES.ENGH00000001 USING SRID 81989&quot;</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;MAXSCALE 99999999</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;MINSCALE 0</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;TRANSPARENCY 60</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;PROJECTION &quot;init=epsg:27700&quot;</font>
<br><font size=2 face="sans-serif">END</font>
<br>
<br>
<br><font size=2 face="sans-serif">2001Urban layer fails with the projection
error, the EnglishHeritageRegions works for the exact same bounding box/scale.</font>
<br><font size=2 face="sans-serif">&nbsp; &nbsp;</font>
<br>
<br>
<br><font size=2 face="sans-serif">We have not applied the METADATA change
as the layers are not external WMS layers and presumably setting the METADATA
wms_srs would provide the same effect as calling layerObj.setProjection?</font>
<br>
<br><font size=2 face="sans-serif">If we restore the code to setProjection
for every layer then the errors go away - but our performance goes down.</font>
<br>
<br>
<br><font size=2 face="sans-serif">Does any of this description allow anyone
to suggest areas that I should get the database team to focus on?</font>
<br>
<br><font size=2 face="sans-serif">Any advice appreciated :-)</font>
<br>
<br><font size=2 face="sans-serif">Simon</font><font size=3 face="sans-serif"><br>
</font>
<br><font size=3 face="sans-serif"><br>
</font>
<hr><font size=2 face="sans-serif"><br>
<i><br>
</i></font>
<p><font size=2 face="sans-serif"><i>Unless stated otherwise above:<br>
IBM United Kingdom Limited - Registered in England and Wales with number
741598. <br>
Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6
3AU</i></font>
<p><font size=2 face="sans-serif"><br>
</font><font size=3 face="sans-serif"><br>
</font>
<br>
<br><font size=3 face="sans-serif"><br>
</font>