[mapserver-dev] RE: MapServer 6.0 Beta 1 - Expression Parser
Lime, Steve D (DNR)
Steve.Lime at state.mn.us
Sun Mar 13 10:08:30 EDT 2011
I think I will pursue an intermediate solution where we could allow simple substitution in a text string. That would reserve the logical syntax for times when more formatting is necessary. If one used quotation marks I think we could also detect attribute bindings and just substitute as before. That would still require change in mapfiles but it would be easy:
TEXT ([item1], [item2]) would become TEXT "[item1], [item2]"
That's actually a cleaner syntax than before... I have to make sure it's feasible, but it should be an easy addition.
From: mapserver-dev-bounces at lists.osgeo.org [mapserver-dev-bounces at lists.osgeo.org] On Behalf Of Daniel Morissette [dmorissette at mapgears.com]
Sent: Thursday, March 10, 2011 10:17 PM
To: mapserver-dev at lists.osgeo.org
Subject: Re: [mapserver-dev] RE: MapServer 6.0 Beta 1 - Expression Parser question
Hopefully the following should work as well, without the need for quotes
around attribute references, right?
TEXT ( [LOCATION]+" "+[OBSERVED]+[UNITS] +"$"+[OBSTIME] )
On 11-03-10 06:21 PM, Lime, Steve D (DNR) wrote:
> This is expected. It's in the RFC and migration guide. We had to treat these
> like true expressions so various formatting functions could be introduced.
> -----Original Message-----
> From: Smith, Michael ERDC-CRREL-NH [mailto:michael.smith at usace.army.mil]
> Sent: Thursday, March 10, 2011 5:18 PM
> To: mapserver-dev at lists.osgeo.org; Lime, Steve D (DNR)
> Subject: MapServer 6.0 Beta 1 - Expression Parser question
> To get the expression parser to label my layers as pre 6.0, I¹ve had to
> change my TEXT statement from
> TEXT ( [LOCATION] [OBSERVED] [UNITS]$[OBSTIME] )
> TEXT ( "[LOCATION]"+" "+"[OBSERVED]"+"[UNITS]" +"$"+"[OBSTIME]" )
> And put quotes around the string fields. Is this expected behavior or is
> this a bug with the new expression parser?
Provider of Professional MapServer Support since 2000
mapserver-dev mailing list
mapserver-dev at lists.osgeo.org
More information about the mapserver-dev