Hi Ben,

Thanks for sending me your configuration - I spotted some differences in my 
layer.xml configuration and the geometry is now being mapped across! I'm using 
the following WFS request in my web browser to get the desired response: 

http://localhost:8080/geoserver/wfs?service=WFS&version=2.0.0&request=GetFeature&typenames=MyPrefix:DepthArea&count=2

I'd now like to be able to visualise the response using QGIS. I've tried adding 
a WFS layer to a new QGIS project, specifying the same request URL, but QGIS 
gives me the error "capabilities document contained no layers". I then tried 
changing the version of the QGIS WFS request to 1.1.0 - this recognised the 
DepthArea layer, but informed me that it wasn't a valid layer and could not be 
added to the map.

For this simple case, is there any request URL that I can put directly into 
QGIS to visualise my DepthArea geometry, or will I need to write some form of 
QGIS plugin before I can visualise my DepthArea features?

Many thanks,

Ryan

-----Original Message-----
From: Ben Caradoc-Davies [mailto:[email protected]] 
Sent: 18 September 2013 09:44
To: Ryan Moody
Cc: Rudy Commenge; [email protected]; Neil Kirk
Subject: Re: [Geoserver-users] App-Schema Geometry Mapping

Ryan,

I was able produce a satisfactory WFS 2.0.0 response (attached) using your 
mapping files and a property file containing dummy data. I have attached the 
files that are different from those in the app-schema tutorial, for your 
inspection (zip file). Please have a look through the zip file and see if you 
missed something.

The query URL was:
http://localhost:8080/geoserver/wfs?service=WFS&version=2.0.0&request=GetFeature&typenames=MyPrefix:DepthArea

All I changed was reformatting, the data store, and the prefix and schema URL. 
I used a gml:GeometryPropertyType in the schema, as discussed.

I used a recent master so I am not sure if the included wfs.xml will work with 
2.3.5, but it only changes a few encoding options and can be ignored.

Kind regards,
Ben.

On 18/09/13 15:56, Ryan Moody wrote:
> Hi Ben,
>
> I've changed my pk_id mapping to use a sourceExpression instead of an 
> idExpression as suggested.
>
> Regarding the geometry issue, I can confirm that I've created both 
> workspaces/gml/namespace.xml and workspaces/gml/workspace.xml. However, when 
> I attempt a WFS 2.0.0 request, I still get the error "The prefix 
> "null" for element "null:Envelope" is not bound."
>
> Any suggestions? Below is my namespace.xml and workspace.xml so that there is 
> no doubt:
>
> = = = Begin workspaces/gml/namespace.xml = = =
>
> <namespace>
>      <id>gml_namespace</id>
>      <prefix>gml</prefix>
>      <uri>http://www.opengis.net/gml/3.2</uri>
> </namespace>
>
> = = = End workspaces/gml/namespace.xml = = =
>
> = = = Begin workspaces/gml/workspace.xml = = =
>
> <workspace>
>      <id>gml_workspace</id>
>      <name>gml</name>
> </workspace>
>
> = = = End workspaces/gml/workspace.xml = = =
>
> Best regards,
>
> Ryan

--
Ben Caradoc-Davies <[email protected]> Software Engineer CSIRO Earth 
Science and Resource Engineering Australian Resources Research Centre
------------------------------------------------------------------------------
LIMITED TIME SALE - Full Year of Microsoft Training For Just $49.99!
1,500+ hours of tutorials including VisualStudio 2012, Windows 8, SharePoint
2013, SQL 2012, MVC 4, more. BEST VALUE: New Multi-Library Power Pack includes
Mobile, Cloud, Java, and UX Design. Lowest price ever! Ends 9/20/13. 
http://pubads.g.doubleclick.net/gampad/clk?id=58041151&iu=/4140/ostg.clktrk
_______________________________________________
Geoserver-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to