[postgis-users] Couldnt convert the postgis geometry to GEOS!

Chris Holmes cholmes at openplans.org
Mon Dec 13 17:52:45 PST 2004


Hey all, apologies for the not so detailed error report, but one of my 
users, when using GeoServer, got this exception buried in a stack trace:

Caused by: java.sql.SQLException: ERROR: Couldnt convert the postgis 
geometry to GEOS!

Does anyone know offhand what could cause such an error?  If not I will 
dig into the issue and make a more detailed bug report if I cant figure it 
out, but thought I would ping the list with what might cause such an 
error, as I have never seen it before.

best regards,

Chris



-- 

---------- Forwarded message ----------
Date: Fri, 10 Dec 2004 16:33:28 +0200
From: Lassi Lehto <Lassi.Lehto at fgi.fi>
To: 'Chris Holmes' <cholmes at openplans.org>
Subject: RE: GeoServer configuration

Hi Chris,

I think we got the problem at the NLS Finland resolved, thanks for your
help! Now to the next one ... :-(

I'm starting to test GeoServer intalled at the Helsinki city surveying
department. Ordinary GET -queries like:

http://wfs.hel.fi/geoserver/wfs/GetFeature?TYPENAME=hel:rakennukset&MAXF
EATURES=1

... work fine (you may test it by yourself), but the following POST
query (involving bounding box):


<?xml version="1.0" encoding="iso-8859-1"?>
<GetFeature xmlns="http://www.opengis.net/wfs"
xmlns:gml="http://www.opengis.net/gml"
xmlns:ogc="http://www.opengis.net/ogc" maxFeatures="1"
handle="geoserverQuery" outputFormat="GML2">
  <Query handle="q01" typeName="hel:rakennukset">
    <PropertyName>the_geom</PropertyName>
    <ogc:Filter>
      <ogc:BBOX>
        <ogc:PropertyName>the_geom</ogc:PropertyName>
        <gml:Box srsName="EPSG:0">
          <gml:coordinates>46000,26000 46500,26500</gml:coordinates>
        </gml:Box>
      </ogc:BBOX>
    </ogc:Filter>
  </Query>
</GetFeature>


... fails with this message:


<?xml version="1.0" ?>
<ServiceExceptionReport
   version="1.2.0"
   xmlns="http://www.opengis.net/ogc"
   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
   xsi:schemaLocation="http://www.opengis.net/ogc
http://schemas.opengis.net/wfs/1.0.0/OGC-exception.xsd">
   <ServiceException>
      problem with FeatureResults:
org.geotools.data.DataSourceException: Could not count q01
	at
org.geotools.data.jdbc.JDBCFeatureSource.count(JDBCFeatureSource.java:41
0)
	at
org.geotools.data.jdbc.JDBCFeatureSource$1.getCount(JDBCFeatureSource.ja
va:225)
	at
org.vfny.geoserver.responses.wfs.FeatureResponse.execute(FeatureResponse
.java:285)
	at
org.vfny.geoserver.responses.wfs.FeatureResponse.execute(FeatureResponse
.java:142)
	at
org.vfny.geoserver.servlets.AbstractService.doService(AbstractService.ja
va:357)
	at
org.vfny.geoserver.servlets.AbstractService.doPost(AbstractService.java:
295)
	at
org.vfny.geoserver.servlets.AbstractService.doPost(AbstractService.java:
249)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tionFilterChain.java:237)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erChain.java:157)
	at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
e.java:214)
	at
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveCo
ntext.java:104)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:5
20)
	at
org.apache.catalina.core.StandardContextValve.invokeInternal(StandardCon
textValve.java:198)
	at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
e.java:152)
	at
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveCo
ntext.java:104)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:5
20)
	at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
:137)
	at
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveCo
ntext.java:104)
	at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
:118)
	at
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveCo
ntext.java:102)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:5
20)
	at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.
java:109)
	at
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveCo
ntext.java:104)
	at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:5
20)
	at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
	at
org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
	at
org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:300)
	at
org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:374)
	at
org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:743)
	at
org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:
675)
	at
org.apache.jk.common.SocketConnection.runIt(ChannelSocket.java:866)
	at
org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool
.java:683)
	at java.lang.Thread.run(Thread.java:534)
Caused by: java.sql.SQLException: ERROR:  Couldnt convert the postgis
geometry to GEOS!
	at
org.postgresql.core.QueryExecutor.executeV2(QueryExecutor.java:287)
	at
org.postgresql.core.QueryExecutor.execute(QueryExecutor.java:104)
	at
org.postgresql.core.QueryExecutor.execute(QueryExecutor.java:43)
	at
org.postgresql.jdbc1.AbstractJdbc1Statement.execute(AbstractJdbc1Stateme
nt.java:517)
	at
org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Stateme
nt.java:50)
	at
org.postgresql.jdbc1.AbstractJdbc1Statement.executeQuery(AbstractJdbc1St
atement.java:233)
	at
org.postgresql.jdbc1.AbstractJdbc1Statement.executeQuery(AbstractJdbc1St
atement.java:221)
	at sun.reflect.GeneratedMethodAccessor90.invoke(Unknown Source)
	at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor
Impl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:324)
	at
org.postgresql.jdbc2.optional.PooledConnectionImpl$StatementHandler.invo
ke(PooledConnectionImpl.java:392)
	at $Proxy1.executeQuery(Unknown Source)
	at
org.geotools.data.jdbc.JDBCFeatureSource.count(JDBCFeatureSource.java:39
9)
	... 34 more
   </ServiceException>
</ServiceExceptionReport>

Could you figure out what might be the problem? The Helsinki server is
version 1.2.0 (You may even check the configuration at
http://wfs.hel.fi/geoserver


With best regards,
Lassi





More information about the postgis-users mailing list