[mapserver-users] Question about WMS Dimension and Cluster

Frode Wiseth Jørgensen frodewj at gmail.com
Thu Nov 17 03:57:28 PST 2016


Hi

When combining Cluster and WMS dimension it seems like the Cluster is
ignored.
This leeds to for instance that attribute "Cluster_FeatureCount" is missing
so using it on SIZE and LABELS won't work and there is no clustering of
objects.

Is Clustering supposed to work when using WMS Dimension?




*Sample of mapfile etc:*


   - GetMap request with dimension filter: &dim_mainmissiontype=Brann
   - gives non clustered map and if for instance Cluster_FeatureCount is
      used, an error is thrown
   - The same GetMap request without dimension filter
   - gives a image with clustered objects



Example mapfile:
    LAYER
        TYPE point
        METADATA
            "WMS_TITLE" "Fire rescue missions2"
            "GML_INCLUDE_ITEMS" "oppdragid,mainmissiontype"
            "WMS_INCLUDE_ITEMS" "oppdragid,mainmissiontype"
            "WMS_MAINMISSIONTYPE_ITEM" "mainmissiontype"
   "WMS_MAINMISSIONTYPE_EXTENT" "Andre oppdrag,Brann,Brannhindrende
tiltak,Ulykke"
   "WMS_MAINMISSIONTYPE_UNITS" ""
            "WMS_MAINMISSIONTYPE_DEFAULT" ""
            "WMS_DIMENSIONLIST" "mainmissiontype"
        END
        CONNECTION "user=xx password=xx dbname=xx host=localhost port=5433"
        CONNECTIONTYPE postgis
        DATA "wkb_geometry FROM (SELECT oppdragid, mainmissiontype,
wkb_geometry FROM firerescuemissions) AS MYTABLE USING UNIQUE oppdragid
USING SRID=4326"
        EXTENT -9223372036.854776 0 31.118456919 9223372036.854776
        NAME "layer_x"
        PROCESSING "CLOSE_CONNECTION=DEFER"
        PROCESSING "CLUSTER_GET_ALL_SHAPES=ON"
        PROCESSING "ITEMS=oppdragid,mainmissiontype"
        PROJECTION "init=epsg:4326" END
        CLASS
            NAME "class"
            STYLE
                ANGLE auto
                COLOR 255 127 0
                LINECAP round
                LINEJOIN round
                MAXSIZE 30
                MINSIZE 10
                OUTLINECOLOR 0 0 0
                SIZE [Cluster_FeatureCount]
                SYMBOL "circle"
                WIDTH 1
            END
        END
        CLUSTER
            MAXDISTANCE 40
            REGION "ellipse"
        END
    END


Example error message:

   - Error using Mapserver 7.0.1 and 7.0.2:
   - msDrawMap(): Image handling error. Failed to draw layer named
      'layer_x'.msPostGISLayerWhichShapes(): Query error. Error
executing query.
      Check server logs
   - Error using Mapserver 6.4.0:
   - msDrawMap(): Image handling error. Failed to draw layer named
      'layer_x'.msPostGISLayerWhichShapes(): Query error. Error
executing query:
      ERROR:  column "Cluster:FeatureCount" does not exist
      LINE 1: select
      "Cluster:FeatureCount",encode(ST_AsBinary(ST_Force_2D...



Running Mapserver on Windows, using binary from gisinterals.com.


Thanks

FrodeWJ
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20161117/13503424/attachment.htm>


More information about the MapServer-users mailing list