[Mapserver-users] PostGIS and CLass - Expression Help

Simpson, Andrew Andrew.Simpson at ssc.nasa.gov
Tue May 4 09:19:14 EDT 2004


Probably not the problem, but your CLASSITEM is "item_x" and your EXPRESSION
has [item_y].

-----Original Message-----
From: Till Adams [mailto:adams at terrestris.de] 
Sent: Tuesday, May 04, 2004 4:57 AM
To: mapserverlist
Subject: [Mapserver-users] PostGIS and CLass - Expression Help


Dear list,

I'm stuck with making an expression on a postgis datasource (code see 
below):
I get no error but also no labels at all - and there are labels, I'm 
sure. I tried everything with quotations, capitalisation in my 
expression, etc. but still get no results :-(.

NAME "xxx"
TYPE ANNOTATION
STATUS ON
CONNECTIONTYPE postgis
CONNECTION "user=admin dbname=datasrc host=localhost"
DATA "the_geom from (select * from view_x) as foo using unique item 
using SRID=31493"

# viewx is a stored query in my database

  METADATA
   'WMS_SRS' 'epsg:31493'
   'WMS_TITLE' 'xxx'
   'WMS_FEATURE_INFO_MIME_TYPE' 'text/html'
  END

   PROJECTION
        	"init=epsg:31493"
   END	
    CLASSITEM "item_x"
    LABELITEM "label"
    LABELANGLEITEM "angle"

    CLASS
     EXPRESSION ([item_y] > 1301) # /^13/
     NAME "name"
      LABEL
       TYPE TRUETYPE
       FONT 'arial'
       SIZE 9
      COLOR 0 0 0
     END
    END
[....]

When making sth. like 'EXPRESSION /^13/' I get results and see labels on 
my map, but that's not enough for us. Maybe there's a problem because 
the data does not result from a postgres table directly?

Any ideas, hints, similar problems out there?

Thanks very much in advance!

Till


_______________________________________________
Mapserver-users mailing list
Mapserver-users at lists.gis.umn.edu
http://lists.gis.umn.edu/mailman/listinfo/mapserver-users



More information about the mapserver-users mailing list