On Tue, Nov 29, 2011 at 10:47 PM, daveD <[email protected]> wrote:
> Ok so I still am having issues with it creating random entries as my primary
> key even after creating a new metadata table and referencing that in my
> GeoServer store.

The short answer is that there is no way right now to make it use the id
you provided.

The table Jukka refers to is there and is the actual way to provide support
for user provided fids at the geotools data store level, user provided fid
support was developed for a sponsor that used GeoTools directly so the
sponsoring did not cover changing GeoServer as well.

And then there is the protocol level. In WFS 1.0 there is no way to ask
for a specific primary key/fid treatment, it is assumed you'll be generating
a new fid value.
In WFS 1.1 in Insert element type has a new attribute, "idgen", described as:

              The idgen attribute control how a WFS generates identifiers
               from newly created feature instances using the Insert action.
               The default action is to have the WFS generate a new id for
               the features.  This is also backward compatible with WFS 1.0
               where the only action was for the WFS to generate an new id.

The possible values there are "UseExisting", "ReplaceDuplicate", "GenerateNew",
however GeoServer does not has code to support them.

The specification is not clear if supporting the above is a mandatory
behavior or not,
but the implementors of the OGC WFS compliance tests evidently did not think
it was required since GeoServer passes all the tests without supporting it.

Also checked briefly WFS 2.0 and it seems the idgen attribute is disappeared
from the spec again, going back to the WFS 1.0 situation.

That said, support for idgen could be developed, at least for WFS 1.1
transactions,
the bits are there, they need to be wired up and tested.

Cheers
Andrea

-- 
-------------------------------------------------------
Ing. Andrea Aime
GeoSolutions S.A.S.
Tech lead

Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

phone: +39 0584 962313
fax:      +39 0584 962313

http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.youtube.com/user/GeoSolutionsIT
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf

-------------------------------------------------------

------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure 
contains a definitive record of customers, application performance, 
security threats, fraudulent activity, and more. Splunk takes this 
data and makes sense of it. IT sense. And common sense.
http://p.sf.net/sfu/splunk-novd2d
_______________________________________________
Geoserver-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to