Hi, I am new to geoserve. We are developing an application using postGIS, geoserver and mapbuilder. I am trying to insert a new feature (polygon), I don’t get any error message, but feature is not added. Can anyone figure out why feature is not added? The message shown on browser is Transaction Status: wfs:SUCCESS New Feature Id: landparcels.null The log file contains 65476 [ÐÅÏ¢] org.vfny.geoserver.wfs.requests.InsertRequest - got type landparcels,http://www.openplans.org/topp 65476 [ÐÅÏ¢] org.vfny.geoserver.servlets.AbstractService - handling request: Lock Id: null releaseAction: ALL handle: null Handle: null landparcels 1 ReleaseAll: false TypeName: landparcels Feature[ id=fid-_ee22aae_1128e6c8a11__7fff , pStatus=Aquired , Possession=null , khasraNo=1 , the_geom=MULTIPOLYGON (((318690.5526623305 3727362.3632548405, 318846.4520270389 3727278.0474675084, 318686.33916598704 3727223.2422057423, 318690.5526623305 3727362.3632548405))) ] 65539 [ÐÅÏ¢] org.vfny.geoserver.servlets.AbstractService - Service handled 65601 [ÐÅÏ¢] org.vfny.geoserver.servlets.AbstractService - handling request: org.vfny.geoserver.wms.requests.GetMapRequest@anonymised.com… 65617 [ÐÅÏ¢] org.vfny.geoserver.servlets.AbstractService - handling request: org.vfny.geoserver.wms.requests.GetMapRequest@anonymised.com… 66258 [ÐÅÏ¢] org.vfny.geoserver.servlets.AbstractService - Service handled 66321 [ÐÅÏ¢] org.vfny.geoserver.servlets.AbstractService - Service handled Yousaf
View this message in context: Area Feature Not added
Sent from the GeoServer - User mailing list archive at Nabble.com.
Yousaf ha scritto:
Hi, I am new to geoserve. We are developing an application using postGIS, geoserver and mapbuilder. I am trying to insert a new feature (polygon), I don't get any error message, but feature is not added. Can anyone figure out why feature is not added? The message shown on browser is *Transaction Status: wfs:SUCCESS New Feature Id: landparcels.null*
Hum, funny the response is a success. Geoserver think it managed to
put the features into the database. Yet, the id is not there.
Hum, does that table have a primary key?
Which version of Geoserver are you using?
Cheers
Andrea
GeoServer version: 1.5.0
Yes there is primary key.
Table structre is
"
CREATE TABLE "LRMIS_SCH".landparcels
(
"Id" integer NOT NULL DEFAULT
nextval('"LRMIS_SCH".landparcels_gid_seq'::regclass),
"pStatus" character varying(30),
"Possession" character varying(1),
"khasraNo" smallint,
the_geom geometry,
CONSTRAINT landparcels_pkey PRIMARY KEY ("Id"),
CONSTRAINT enforce_dims_the_geom CHECK (ndims(the_geom) = 2),
CONSTRAINT enforce_geotype_the_geom CHECK (geometrytype(the_geom) =
'MULTIPOLYGON'::text OR the_geom IS NULL),
CONSTRAINT enforce_srid_the_geom CHECK (srid(the_geom) = 32643)
)
WITHOUT OIDS;"
aaime wrote:
Yousaf ha scritto:
Hi, I am new to geoserve. We are developing an application using
postGIS, geoserver and mapbuilder. I am trying to insert a new feature
(polygon), I don't get any error message, but feature is not added. Can
anyone figure out why feature is not added? The message shown on browser
is *Transaction Status: wfs:SUCCESS New Feature Id: landparcels.null*
Hum, funny the response is a success. Geoserver think it managed to
put the features into the database. Yet, the id is not there.
Hum, does that table have a primary key?
Which version of Geoserver are you using?
Cheers
Andrea
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users
--
View this message in context: http://www.nabble.com/Area-Feature-Not-added-tf3756866.html#a10619878
Sent from the GeoServer - User mailing list archive at Nabble.com.
Yousaf ha scritto:
GeoServer version: 1.5.0
Yes there is primary key.
Table structre is
"
CREATE TABLE "LRMIS_SCH".landparcels
(
"Id" integer NOT NULL DEFAULT
nextval('"LRMIS_SCH".landparcels_gid_seq'::regclass),
"pStatus" character varying(30),
"Possession" character varying(1),
"khasraNo" smallint,
the_geom geometry,
CONSTRAINT landparcels_pkey PRIMARY KEY ("Id"),
CONSTRAINT enforce_dims_the_geom CHECK (ndims(the_geom) = 2),
CONSTRAINT enforce_geotype_the_geom CHECK (geometrytype(the_geom) =
'MULTIPOLYGON'::text OR the_geom IS NULL),
CONSTRAINT enforce_srid_the_geom CHECK (srid(the_geom) = 32643)
) WITHOUT OIDS;"
I see. This case should be supported by the autoincrement FID mapper,
but apparently there are troubles. I have a feeling the record
is being inserted in the table, the key generated, but the returned
feature id is incorrect (null).
Can you double check and confirm that?
Also, if you run the following:
select currval(pg_get_serial_sequence("LRMIS_SCH.landparcels", "Id"));
what happens? Does the current sequence value pop out?
We have various ways to try and grab back the generated primary key
value, that tries to cope with various postgis versions, the code we use is here:
http://svn.geotools.org/geotools/branches/2.3.x/plugin/postgis/src/org/geotools/data/postgis/fidmapper/PostGISAutoIncrementFIDMapper.java
Apparently, they are all failing...
Cheers
Andrea
Yousaf ha scritto:
GeoServer version: 1.5.0
Yes there is primary key.
Table structre is
"
CREATE TABLE "LRMIS_SCH".landparcels
(
"Id" integer NOT NULL DEFAULT
nextval('"LRMIS_SCH".landparcels_gid_seq'::regclass),
"pStatus" character varying(30),
"Possession" character varying(1),
"khasraNo" smallint,
the_geom geometry,
CONSTRAINT landparcels_pkey PRIMARY KEY ("Id"),
CONSTRAINT enforce_dims_the_geom CHECK (ndims(the_geom) = 2),
CONSTRAINT enforce_geotype_the_geom CHECK (geometrytype(the_geom) =
'MULTIPOLYGON'::text OR the_geom IS NULL),
CONSTRAINT enforce_srid_the_geom CHECK (srid(the_geom) = 32643)
) WITHOUT OIDS;"
Oh, another thing. What happens if you move this table to the
default schema ("public"). Does it work there?
Cheers
Andrea