Thanks so much, David, I've been digging through the PostGIS documentation but 
never could seem to figure out the language for describing where the issue was 
taking place.

-Elijah

************
Elijah Meeks
http://dhs.stanford.edu
Digital Humanities Specialist
Academic Computing Services
Stanford University
[email protected]
(650)387-6170

----- Original Message -----
From: "David Winslow" <[email protected]>
To: "Elijah Meeks" <[email protected]>
Cc: [email protected]
Sent: Thursday, July 14, 2011 9:18:00 AM
Subject: Re: [Geoserver-users] PostGIS Views

This happens when GeoServer can't properly determine the geometry type for the 
column; it defaults to the default point style which is the most general (it 
will render centroids for polygons and midpoints for linestrings, so any vector 
data can be rendered with the point style.) If you add "styles=polygon" to the 
URL for your OpenLayers preview then it should work. You can also set this as 
the default in the configuration for the layer. 

You can look in the PostGIS manual for details on how to properly register your 
view with PostGIS to avoid this sort of issue in the future. 

-- 
David Winslow 
OpenGeo - http://opengeo.or/g 


On Thu, Jul 14, 2011 at 12:11 PM, Elijah Meeks < [email protected] > wrote: 


I've got Geoserver 2.1 connected to a PostGIS database and it displays the 
tables as layers just fine: 
http://dhs.stanford.edu/dh/geospat/polys.PNG 

but when I try to server a view as a layer, it looks like the geometry is 
displayed as a collection of points instead of polygons: 
http://dhs.stanford.edu/dh/geospat/points.PNG 

The query that produces this result is simply the previous table WHERE id = X, 
so it's not like I'm running anything that changes the way the geometry is 
being formatted. 

Thanks in advance for any suggestions, 
Elijah 

************ 
Elijah Meeks 
http://dhs.stanford.edu 
Digital Humanities Specialist 
Academic Computing Services 
Stanford University 
[email protected] 
(650)387-6170 


------------------------------------------------------------------------------ 
AppSumo Presents a FREE Video for the SourceForge Community by Eric 
Ries, the creator of the Lean Startup Methodology on "Lean Startup 
Secrets Revealed." This video shows you how to validate your ideas, 
optimize your ideas and identify your business strategy. 
http://p.sf.net/sfu/appsumosfdev2dev 
_______________________________________________ 
Geoserver-users mailing list 
[email protected] 
https://lists.sourceforge.net/lists/listinfo/geoserver-users 


------------------------------------------------------------------------------
AppSumo Presents a FREE Video for the SourceForge Community by Eric 
Ries, the creator of the Lean Startup Methodology on "Lean Startup 
Secrets Revealed." This video shows you how to validate your ideas, 
optimize your ideas and identify your business strategy.
http://p.sf.net/sfu/appsumosfdev2dev
_______________________________________________
Geoserver-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to