Opened 14 years ago

Last modified 14 years ago

#3320 new enhancement

Support MAPSHAPE param in QUERY

Reported by: rbranson Owned by: sdlime
Priority: normal Milestone:
Component: MapServer CGI Version: 5.6
Severity: normal Keywords:
Cc:

Description

We're using NQUERY to detect if a list of layers are within a bounding box, but the NQUERY mode returns and processes every single shape. We're just interested in a single boolean answer, but for a bounding box, and it'd be nice if we could use MAPSHAPE param in the regular QUERY mode. The patch for it is simple, it's just another case in mapserv.c around like 1768 to support the FROMUSERSHAPE QueryCoordSource.

Change History (1)

comment:1 by sdlime, 14 years ago

Mode=query returns only 1 result for only 1 layer. You can use the new-style templating with mode=nquery to do this I think, for example:

  <!-- MapServer Template -->
  <resultset name="layer1">Layer 1 Exists</resultset>
  <resultset name="layer2">Layer 2 Exists</resultset>
  <resultset name="layer3">Layer 3 Exists</resultset>
  <resultset name="layer4">Layer 4 Exists</resultset>

With this template I believe the processing of individual features won't happen, however you will get the text in the resultset tag if the layer has results. So, a simple mode=nquery&mapext=[...] will get you a layer list via this mechanism.

Steve

Note: See TracTickets for help on using tickets.