Opened 16 years ago

Last modified 13 years ago

#2424 new defect

Ability to limit number of query results per layer

Reported by: dmorissette Owned by: dmorissette
Priority: normal Milestone: 6.2 release
Component: MapServer C Library Version: svn-trunk (development)
Severity: normal Keywords:
Cc: assefa, sdlime

Description

Tickets #1686 and #2423 required the addition of a maxresults argument to the msQueryByPoint() function in order to properly handle WMS GetFeatureInfo's FEATURE_COUNT. A preliminary fix for this was committed in r7147.

It has then been suggested that we extend the concept of maxresults as follows:

  • Make maxresults a layer-level parameter
  • Make it work for all query types (point, rect, shape, attributes)
  • Deal with returning only the 'maxresults' closest results per layer vs returning the first matching shapes in each layer (at least document the issue, or if possible extend the query code to return the 'maxresults' closest shapes)
  • Make WFS queries/filters use maxresults at query time instead of limiting the number of results only at presentation time (i.e. in msGMLWriteWFSQuery)
  • Make the maxresults layer member visible to MapScript

A RFC will be required for this (in 5.2)...

Change History (6)

comment:1 by dmorissette, 16 years ago

See also ticket #2605 about passing MAXFEATURES to spatial databases

comment:2 by sdlime, 16 years ago

Just for background. RFC 36 implements a limit parameter as part of the [feature ...]feature tag although that's well after a query was done.

Personally I favor a layer level parameter that:

  • the msQueryBy... functions respect
  • database drivers respect

There is a MAXFEATURES parameter already at the layer level (used for drawing only) and care must be taken to not confuse users. Perhaps the use can be merged somehow or the parameters could be named explicitly, e.g. MAXDRAWFEATURES and MAXQUERYFEATURES.

Steve

comment:3 by sdlime, 16 years ago

Milestone: 5.2 release5.4 release

Moving to 5.4...

Steve

comment:4 by dmorissette, 15 years ago

Milestone: 5.4 release6.0 release

comment:5 by dmorissette, 13 years ago

See also ticket #3739 (Need to define a means of limiting the number of features drawn)

comment:6 by sdlime, 13 years ago

Milestone: 6.0 release6.2 release

Moving to 6.2, we'll need an RFC to deal with this across the board.

Steve

Note: See TracTickets for help on using tickets.