[OpenLayers-Users] Request with wrong column name
Bart van den Eijnden
bartvde at osgis.nl
Wed Jan 27 10:51:28 EST 2010
Hi,
use geometry_column instead of geometryName.
Bart
On Jan 27, 2010, at 4:46 PM, Luís de Sousa wrote:
> Hello Gabriel,
>
> Thank you for your reply. I add the geometryName property to the WFS constructor; it now is:
>
> wfs = new OpenLayers.Layer.WFS(
> "Tanques",
> "/geoserver/wms",
> {typename: 'insaar:M_TANQUE',
> srs: 'EPSG:82176'
> },
> {
> typename: "M_TANQUE",
> featureNS: "http://insaar.inag.pt",
> geometryName: "shape",
> commitReport: function() {
> },
> extractAttributes: true,
> }
> );
>
> This had no effect, in the request the feature is still identified with "the_geom". I could change the column name in the database, but would prefer some workaround with the code.
>
> Thanks,
>
> Luís
>
>
> On Tue, Jan 26, 2010 at 10:12 PM, Gabriel Nolasco <nolasco_gabriel at yahoo.com.br> wrote:
> Hello Luis,
>
> If you are using a vector layer with a WFS protocol you can use the property 'geometryName' to set the name of the geometry column. Default is 'the_geom'[1]
> You can see an example of the WFS protocol usage at OpenLayers examples page [2]
>
> [1] http://dev.openlayers.org/docs/files/OpenLayers/Protocol/WFS/v1-js.html#OpenLayers.Protocol.WFS.v1.geometryName
> [2] http://openlayers.org/dev/examples/wfs-protocol-transactions.html
>
> Best regards,
> Gabriel Nolasco
>
> _______________________________________________
> Users mailing list
> Users at openlayers.org
> http://openlayers.org/mailman/listinfo/users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20100127/7dd601d5/attachment.html
More information about the Users
mailing list