Hi Jesse,

The issue is that the underlying database instance is not being 
initialized properly with all the spatial functions. This is an known 
issue. I am going to create a jira for it.

http://jira.codehaus.org/browse/GEOT-2037

As a workaround, what you do is the following:

1. pre-create an h2 database file
2. load all the spatial stuff manually (there is a script in the module 
to do this)
3. then connect the datastore

I will try to tackle this one soon so I can get some good testing out of 
you :).

-Justin

Jesse Eichar wrote:
> Hi,
> 
> I am playing with the H2 datastore.  Is it normal and acceptable to get 
> the warning: 
> 
>> Sep 15, 2008 9:54:26 AM org.geotools.jdbc.JDBCFeatureStore 
>> buildFeatureType
>> WARNING: Error occured determing srid for testType.the_geom
>> org.h2.jdbc.JdbcSQLException: Function GETSRID not found; SQL 
>> statement: SELECT getSRID("the_geom") FROM "testType" WHERE "the_geom" 
>> is not null LIMIT 1 [90022-40]
> 
> If not what have I done wrong.  I used the Datastore's createSchema to 
> create the table.  Here is the featuretype declaration:
> 
>>     builder.setName("testType")
>>     builder.setSRS("EPSG:4326")
>>     builder.crs(DefaultGeographicCRS.WGS84).add("the_geom", 
>> classOf[Polygon])
>>     builder.add("metadataId", classOf[String]
> 
> Jesse
> 
> 
> ------------------------------------------------------------------------
> 
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Geotools-devel mailing list
> Geotools-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/geotools-devel


-- 
Justin Deoliveira
Software Engineer, OpenGeo
http://opengeo.org

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Geotools-devel mailing list
Geotools-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geotools-devel

Reply via email to