[mapserver-users] different attribute values of "subfeatures" and its visualization

Lars Lingner ml at lingner.eu
Thu Jul 10 08:02:01 EDT 2008


Hello list,

I have a bunch of spatial data in my PostgreSQL/PostGIS-DB. They are
polyline features. Each polyline has some "global" attributes, which
means the attributes are describing the whole line. Length is such an
attribute but also the overall diameter could be one. To make it more
visual, the polylines should represent tubes.

A polyline consists (of course) of one or more lines. Such a line I
would call subfeature. Every line has its own length and also e.g. its
own diameter attribute. Sometimes the values of diameter are equal at
the whole length, that is no problem. I have issues if the values are
not equal.

My idea was to give the subfeatures with different values an different
stroke width, to represent the diameter, or at least an different color.

Is there a way to tell mapserver that a feature should have such a
complex visualization? I have the coordinates stored at the DB and can
query it, if it helps at any point.

1)
First I thought I cut the features apart and can then define classes in
my mapfile. The drawback is then: I'll loose the state of the whole
feature. I want to be able to query the feature and the response should
include the "global" attributes and the ones specified by the
subfeature. Hmmm...

2)
I also could store the "global" attributes with the subfeature. But then
I'll end up with a lot redundancy, which I want to avoid. Hmmm...

At the end I want to define an WMS and WFS. With way 1) I also get a lot
of features returned by the WFS which makes the handling at the client
very memory consuming and very very slow.

Therefore I want to start with the WMS but now I'm at a dead end.

My question is:

Is there a an other way (independent from my 1+2) to make the sizing of
a feature depended on the attribution on a subfeature?


I hope I could make myself understandable. But with such a complex issue
(isn't it?) I'll happy to answer any open questions.

Thanks in advance


lars


More information about the mapserver-users mailing list