Need Help Displaying Info from DBFs

Michael Elepano michael at LIVEPROCESS.COM
Fri Jan 14 13:08:46 EST 2005


Hey:

I've been using MapServer for about a month now and have gotten 
relatively far with it.  But now I've hit a brick wall.

The problem I'm having is showing info from DBFs on my map of the US.  
I've got two DBFs (one with all the US counties and one with data-- say 
occurences of avalanches-- for each of those county).  I'm trying to 
color code each county according to occurences of avalanches.

Each DBF has a column called FIPS.  The avalanche DBF has a column 
called COUNT that is the basis for my colors.  I can use EXPRESSION to 
single out any column in my county DBF, but I can't seem to reach my 
avalanche DBF.

I'm assuming I'll need to do a JOIN.  My attempt follows below.  Any 
advice would be appreciated.

Michael

######################
## my attempt at an avalanche layer
######################
        LAYER
                NAME "layerAvalanche"
                TYPE POLYGON
                STATUS ON
                DATA "counties.dbf"
                PROJECTION
                        "proj=latlong"
                        "ellps=GRS80"
                        "datum=NAD83"
                END
                                        	
                CLASS
                        NAME "classGreen"
                        OUTLINECOLOR 255 0 255
                        COLOR 0 255 0
                        EXPRESSION ([COUNT] > 5)
                END
        	
                JOIN
                        NAME "joinAvalanche"
                        TABLE "C:\my\path\to\avalanches.dbf"
                        FROM "FIPS"
                        TO "FIPS"
                END
        END
  


More information about the mapserver-users mailing list