[mapserver-users] MAXSCALEDENOM [scale_field]

Lime, Steve D (DNR) Steve.Lime at state.mn.us
Thu Jul 15 11:03:09 PDT 2010


I wonder if you could access the current computed scale denominator in expression (or the DATA statement) and get the same effect...

e.g.:

  CLASS
     EXPRESSION ('[category]' eq 'poi' && [priority] < SCALE)
     ...
  END

Steve



-----Original Message-----
From: mapserver-users-bounces at lists.osgeo.org [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Daniel Degasperi
Sent: Thursday, July 15, 2010 5:02 AM
To: Lime, Steve D (DNR)
Cc: mapserver-users at lists.osgeo.org
Subject: Re: [mapserver-users] MAXSCALEDENOM [scale_field]

Hi Steve,
maybe it's easier to explain with a mapfile example:

LAYER
     NAME "POI"
     TYPE POINT
     CONNECTIONTYPE postgis
     CONNECTION "user=somebody password=something dbname=test 
host=localhost"
     DATA "the_geom FROM (SELECT gid, category, priority, the_geom FROM 
poi) AS foo USING UNIQUE gid"
     ...
     CLASS
         EXPRESSION ('[category]' eq 'poi')
         MAXSCALEDENOM [priority]
         ...
     END
     ...
END

In this case I've one single class  for each category and the 
MAXSCALEDENOM get the value from the priority attribute of my datasource.
As it is now, MapServer does not support this feature and I've to repeat 
every single category for each different priority value.

Best regards,
Daniel


Am 14/07/2010 23:53, schrieb Lime, Steve D (DNR):
> MapServer doesn't support layer-level binding only feature-level binding. I'm having trouble seeing the value. Can you explain further?
>
> Steve
> ________________________________________
> From: mapserver-users-bounces at lists.osgeo.org [mapserver-users-bounces at lists.osgeo.org] On Behalf Of Daniel Degasperi [daniel.degasperi at r3-gis.com]
> Sent: Wednesday, July 14, 2010 7:54 AM
> To: mapserver-users at lists.osgeo.org
> Subject: [mapserver-users] MAXSCALEDENOM [scale_field]
>
> Hi,
> I've tried to read the MAXSCALEDENOM value from a attribute in my
> datasource, but mapserver throw's a parsing error.
> Probably because such feature does not exist in mapserver.
>
> Are there any intentions to implement this?
> It could be interesting for layers, whose data has different priorities
> but the same styling.
> With this feature I can avoid repeating the classes for every priority.
>
> Best regards,
> Daniel
> _______________________________________________
> mapserver-users mailing list
> mapserver-users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>    

_______________________________________________
mapserver-users mailing list
mapserver-users at lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users



More information about the MapServer-users mailing list