[mapserver-users] drawing multiple layers from postgis

Michael McInnis mmcinnis59 at msn.com
Thu Aug 8 11:16:53 PDT 2013


Hopefully, this is an easy one.
I'm trying to build a scale sensitive .map file using points from postgis.
I can successfully draw the shapefile states with a single points layer from postgis.However, if I add an additional points layer and attempt to draw it the layer comes up blank.If I remove the leading postgis points layer from the .map file the new points layer will now display.IE I can only draw the first occurrence of a postgis layer in the map file.
How do you define multiple postgis layers so that you can pick and choose layers for display?
LAYER        NAME states        DATA STATES        STATUS ON        TYPE Polygon                CLASS            OUTLINECOLOR 255 255 255            COLOR 155 155 155        END # Class    END # Layer     LAYER        CONNECTIONTYPE POSTGIS        NAME business_rd2        CONNECTION "host=localhost dbname=Business user=postgres password=wacadmin port=5432"        PROCESSING "CLOSE_CONNECTION=DEFER"        DATA "geom From business_rd2 as rd2 using unique id using srid=4326"         #MINSCALE 100000 	STATUS ON        TYPE POINT        CLASS            SYMBOL 'circle'                SIZE 2                COLOR 255 0 0             END        END # Class    END # Layer
    LAYER        CONNECTIONTYPE POSTGIS        NAME business_rd1        CONNECTION "host=localhost dbname=Business user=postgres password=wacadmin port=5432"        PROCESSING "CLOSE_CONNECTION=DEFER"        DATA "geom From business_rd1 as rd1 using unique id using srid=4326"         #MINSCALE 100000 	STATUS ON        TYPE POINT        CLASS            SYMBOL 'circle'                SIZE 2                COLOR 255 0 0             END        END # Class    END # Layer
Michael McInnis
6033 44th Ave. N.E.
Seattle, WA 98115
206 517-4701 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20130808/10e21ba1/attachment.htm>


More information about the MapServer-users mailing list