[postgis-users] Errors while creating database from org.geotools.data.postgis
Andy Colson
andy at squeakycode.net
Thu Dec 19 09:44:09 PST 2013
On 12/19/2013 9:53 AM, Thomas Schweikle wrote:
> Hi!
>
> I am seeing various errors while a routine tries to create databases.
> I'm having trouble interpreting these errors:
> --- SNIP
> 18:35:34,895 ERROR Dez 18, 2013 6:35:34 PM
> org.geotools.data.postgis.PostgisDataStore createSchema
> Information: CREATE TABLE "public"."npp" ("npp_fid" serial PRIMARY
> KEY, "the_geom" GEOMETRY, "Name" VARCHAR(256), "Longitude" DOUBLE
> PRECISION, "Latitude" DOUBLE PRECISION);
> --- SNAP
> To me it looks like they are trying to create a database, but without
> rights to create the database? Any way to find the user whom is to
> create this database?
>
> --- SNIP
> 18:35:35,069 ERROR Dez 18, 2013 6:35:35 PM
> org.geotools.data.postgis.PostgisDataStore createSchema
> Information: DELETE FROM GEOMETRY_COLUMNS WHERE f_table_catalog='' AND
> f_table_schema = 'public'AND f_table_name = 'npp';
> --- SNAP
> They want to delete datasets, but fail. Access rights wrong? Wrong
> user? Which user was intended? Which user was used? Or -- is this
> database not enabled to use postgis??
>
> --- SNIP
> 18:35:35,080 ERROR Dez 18, 2013 6:35:35 PM
> org.geotools.data.postgis.PostgisDataStore createSchema
> Information: INSERT INTO GEOMETRY_COLUMNS VALUES
> ('','public','npp','the_geom',2,4326,'POINT');
>
> 18:35:35,089 ERROR Dez 18, 2013 6:35:35 PM
> org.geotools.data.postgis.PostgisDataStore createSchema
> Information: ALTER TABLE "public"."npp" ADD CONSTRAINT
> enforce_srid_the_geom CHECK (SRID(the_geom) = 4326);
>
> 18:35:35,097 ERROR Dez 18, 2013 6:35:35 PM
> org.geotools.data.postgis.PostgisDataStore createSchema
> Information: ALTER TABLE "public"."npp" ADD CONSTRAINT
> enforce_dims_the_geom CHECK (ndims(the_geom) = 2);
>
> 18:35:35,123 ERROR Dez 18, 2013 6:35:35 PM
> org.geotools.data.postgis.PostgisDataStore createSchema
> Information: ALTER TABLE "public"."npp" ADD CONSTRAINT
> enforce_geotype_the_geom CHECK (geometrytype(the_geom) = 'POINT'::text
> OR the_geom IS NULL);
>
> 18:35:35,133 ERROR Dez 18, 2013 6:35:35 PM
> org.geotools.data.postgis.PostgisDataStore createSchema
> Information: CREATE INDEX "spatial_npp_the_geom" ON "public"."npp"
> USING GIST ("the_geom");
> --- SNAP
>
> Maybe someone 's got an idea how to find out what was going on here!
>
This doesn't look like the PostgreSQL error log, is it?
1'st I'd say find the error log from PG, not from geotools.
2'nd, in your postgresql.conf make sure your log_line_prefix has things
like %d (databasename) and %u (username)
-Andy
More information about the postgis-users
mailing list