[OpenLayers-Users] Display Point from Polygon WFS

Ziegler Stefan Stefan.Ziegler at bd.so.ch
Thu Apr 2 02:03:49 EDT 2009


You can create a view ("create or replace view as .....") instead of a
table. Then you will not have any redundance problems.

regards
Stefan

> -----Ursprüngliche Nachricht-----
> Von: Florent Gravin [mailto:florent.gravin at bluecham.net]
> Gesendet am: Donnerstag, 2. April 2009 06:47
> An: Vivien Deparday
> Cc: users at openlayers.org
> Betreff: Re: [OpenLayers-Users] Display Point from Polygon WFS
> 
> I use PostGIS database, and then, geoserver.
> 
> for exemple, i have a table called "countries", with 
> population, density 
> attribues, whom geometry is polygon.
> if i understand, you suggest to create a new table 
> "countries_point" from 
> countries, using ST_Centroid to get point as the geom column, 
> and duplicate 
> attributes (population, density)
> so i have to similars tables... and then i call a request WFS on 
> "countries_point" ?
> 
> 
> I guess it works, but it's not very good to have a redundance 
> of 2 tables... 
> (updates...)
> there is no tools like WFS special parameter, or openlayers 
> tips to display 
> polygon feature as point ? (we can do it easly with WMS)
> 
> thks
> 
> ----- Original Message ----- 
> From: "Vivien Deparday" <vivien.deparday at gmail.com>
> To: "floflo" <florent.gravin at bluecham.net>
> Cc: <users at openlayers.org>
> Sent: Thursday, April 02, 2009 11:21 AM
> Subject: Re: [OpenLayers-Users] Display Point from Polygon WFS
> 
> 
> > Hi,
> >
> > I'm not sure what technology you use on the server side but 
> if you use a 
> > spatial database like PostGIS, you can use the function 
> ST_Centroid( 
> > geometry ) in the database and then directly request the 
> centroids instead 
> > of the polygons.
> > Cheers,
> >
> > Vivien
> >
> > floflo wrote:
> >> Hi,
> >>
> >> i request a WFS query on a layer full of complex polygon.. 
> rendering is 
> >> too slow
> >> anyway, I just want to display a POINT for each POLYGON 
> (in the middle)
> >>
> >> purpose: display proportionnal symbol from an attribute of 
> a polygon 
> >> layer (exemple, layer : country, propSymbol on Population)
> >>
> >> do you have any issue ?
> >> thanks
> >>
> > 
> 
> _______________________________________________
> 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/20090402/e5cd70a6/attachment.html


More information about the Users mailing list