Hi James,

I am not 100% certain about the original problem. However let me share two ways that i use to merge more than one layer into one parent layer:

I either use CONNECTIONTYPE UNION as is described here: https://mapserver.org/mapfile/union.html

Or I use WMS_LAYER_GROUP that I simply define in all "child" layers. There is no need for a "parent" in this case for all layers in the group can be queried at once by calling the layer group as a normal layer in the WMS request.  I do tend to keep the names for those groups simple and without any extra characters.
For instance if I have

"WMS_LAYER_GROUP"  "/my_sweet_group"

The call can simply be something like
http://<my_url.com>/cgi-bin/mapserv?map=<path_to_mapfile>wms.map&LAYERS=
my_sweet_group&...

Documentation: https://mapserver.org/ogc/wms_server.html

If you need SRS transformation, I would define that on the level of the entire map (WEB - block) rather than on the layer level. That can be confusing from my point of view.

I hope this helps some?

Best

Lars


Lars Fricke
Forschung & Entwicklung

+49(0)39602-183097
+49(0)39602-183098

SkenData GmbH
Mühlendamm 8B
18055 Rostock
www.skendata.de


Wert14


www.wert14.de

Geschäftsführer: Jon Meis und Sven Jantzen
Amtsgericht Rostock HRB 12937

Am 28.10.19 um 03:55 schrieb James Gardner:
Hi Lars,

Sub Layer
In zzz.map

<<+++
LAYER
CONNECTION "host=**** dbname=**** user=**** password=****"
CONNECTIONTYPE POSTGIS
DATA "the_geom FROM (select id,the_geom,time) as subquery using unique id"
GROUP "layer56_simulation_15044"
METADATA
"wms_srs" "EPSG:900913"
"gml_the_geom_type" "point"
"wms_keywordlist" "simulation_id 15044"
"gml_include_items" "*"
"gml_geometries" "the_geom"
"wms_group_title" "/2019-09-27/09:00 - test (ID: 15044)"
"wms_title" "*****"
END # METADATA
NAME "layer55_simulation_15044 "
PROCESSING "CLOSE_CONNECTION=DEFER"
PROJECTION
"init=epsg:900913"
END # PROJECTION
STATUS ON
TEMPLATE "zzzzz.html"
TILEITEM "location"
TOLERANCE 20
TYPE POINT
UNITS METERS
END
+++


Parent layer
<<<+++
LAYER
CONNECTION "http://localhost/cgi-bin/mapserv?map=/data/web_projects/mapproxy/docker/ows/zzzz.map&"
CONNECTIONTYPE WMS
METADATA
"wms_srs" "EPSG:900913 EPSG:4326"
"wms_extent" "13048989.6381759 -4108382.56980896 13049321.6706854 -4107853.60807286"
"wms_layer_group" "/2019-09-27/09:00 - test (ID: 15044)"
"wms_name" "layer56_simulation_15044"
"wms_feature_info_mime_type" "text/html"
"wms_format" "image/png"
"wms_keywordlist" "simulation_id 15044,status complete"
"wms_server_version" "1.1.1"
"wms_title" "********"
END # METADATA
NAME "layer56_simulation_15044"
PROJECTION
"init=epsg:900913"
END # PROJECTION
STATUS ON
TEMPLATE "zzzz.html"
TILEITEM "location"
TOLERANCE 20
TYPE RASTER
UNITS METERS
CLASS
NAME "*******"
STYLE
SIZE 20
SYMBOL "********"
END # STYLE
END # CLASS
+++


When I do a getFeatureInfo on the parent layer, it returns nothing, when it should query the sublayer and return something...
Thanks
JG..


This e-mail and any files transmitted with it are intended only for the use of the addressee(s). It may contain information that is confidential and privileged, in which case neither is intended to be waived or lost by mistaken delivery to you. If you are not an intended recipient, any use, interference with, disclosure, distribution or copying of this material is unauthorised and prohibited. If you receive this e-mail in error, please notify the sender by return e-mail and delete the message and any attachments from your system. Unless specifically indicated, this e-mail does not constitute formal advice or commitment by the sender or the Western Australian Land Information Authority (Landgate). Information in this message not relating to the official business of Landgate shall be understood as neither given nor endorsed by it. It is your responsibility to check any attachments for viruses and defects before opening or sending them on. Landgate’s liability is limited to re-supplying affected attachments.


_______________________________________________
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users


_______________________________________________
mapserver-users mailing list
mapserver-users@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/mapserver-users

Reply via email to