[MAPSERVER-USERS] point,polygon and line layers in single map file

Stephen Woodbridge woodbri at swoodbridge.com
Thu Nov 6 07:21:24 PST 2008


S.Reena wrote:
> Hi All,
> 
> Is it possible to make a single map file having all the three types of
> layers ( point, polygon and line) and if yes how to store that in
> geometry_columns table in postgresql which gives duplication error ? 

Yes, all mapfiles tend to have multiple layers, I have some with 100s of 
layers. Think about the problem like this:

mapfile  == map
layer    == one type of data (point, line, polygon, label, etc)
             from one particular data source.
class    == one particular subset of data in a layer that you want to
             isolate and render in a particular manner

So in you question above:

You would have three or more layers. At least one for each point, line, 
polygon data type. In postgres these would each be a different table or 
tables.

Even while roads and railroads are both lines, you might want them 
separated into two separate tables in postgres. and you would have two 
separate layers to render them.

HTH,
   -Stephen Woodbridge
    http://imaptools.com/



More information about the MapServer-users mailing list