Shading polygon shapes by joining to MySQL
Kieran J. Ames
kames at keyspanenergy.com
Thu Jan 11 12:11:21 PST 2001
Hello All,
I'm trying to put all the pieces together, but am surely making little
headway.
I've set up a .map file that enables me to render Zip Code polygons. I
can also shade the polygons using REGEXP expressions.
All of this I'm doing with a basic mapserver forms-based app and the
mapimage.class applet. I thought I could join the Zip code's .dbf file
to another .dbf file and shade the polygons based on one of the fields
available via the join. I then discovered that you can't do this... (if
I read the mail archives right).
The platform I'm on is NT4.0, PHP Version 4.0.3pl1, MapServer Version
3.3.012, MapScript Version (Nov 01, 2000) and MySQL.
All are working. I also downloaded the DM Solutions gmap demo package
and, aside from the query items portion, it's working just fine. (Nice
app, Dan! But, way too complicated for my Intro to Mapscript!)
The goal I'm looking for would require, I think, mapscript and php,
since I'm on NT.
I'd like to show zip code polygons (like I'm doing now), but allow the
user to select an attribute from within the MySQL db. eg: Render the Zip
Codes from the existing zipcode shape file, and shade them based on the
results of the db call. I can get my web-hands on all the data for this
via Perl, cgi, web forms, etc. but the rendering has got me stopped in
my tracks.
Can anyone point me toward an example site that can accomplish such a
feat? I don't think it's far-fetched. I just can't figure a way to
combine these 2 pieces of functionality.
As always, thanks for any assistance.
Kieran
More information about the MapServer-users
mailing list