So you'll be doing a mode=itemfeaturenquery or itemfeaturequery. The difference 
is in the number of features the initial attribute query can match n or 1. The 
mapfile won't help much. The only trick here is getting the line layer setup 
correctly for attribute queries. Basically, besides being queryable in the 
first place (e.g. set TEMPLATE),  all that means is that you need to set a 
validation pattern for the qstring parameter so that you can validate what 
users enter.

>From there the URLs will be of the form:

  
/cgi-bin/mapserv?map=your.map&slayer=lines&qitem=item&qstring=string&qlayer=polygons&mode=itemfeaturenquery

You can query multiple layers using the slayer, just don't use qlayer in that 
case and the query will run against all queryable layers you have ON or have 
status=DEFAULT.

Steve

From: Weisbender, Eric [mailto:[email protected]]
Sent: Tuesday, June 24, 2014 10:12 AM
To: Lime, Steve D (MNIT); [email protected]
Subject: RE: FEATUREQUERY with SLAYER

Thanks Steve,

I think a look at the mapfile would be helpful.  Here is my scenario...  I have 
a file with multiple linear features in it.  I would like to type in a line 
name and return all the polygons that intersect that line.  I think I'm close 
but I just need to understand better how slayer works.

Thanks,

Eric Weisbender
GIS Program Lead
Western Area Power Administration
(720) 962-7280
[email protected]<mailto:[email protected]>

From: Lime, Steve D (MNIT) [mailto:[email protected]]
Sent: 2014, June, 24 8:38 AM
To: Weisbender, Eric; 
[email protected]<mailto:[email protected]>
Subject: RE: FEATUREQUERY with SLAYER

I've used it successfully in a number of places, here's one example:

  http://deli.dnr.state.mn.us/data_search.html

The search by county option uses mode=featurenquery. I can provide more detail 
if you need it since much of the configuration (and there's not much to it) is 
in the mapfile.

Steve

From: 
[email protected]<mailto:[email protected]>
 [mailto:[email protected]] On Behalf Of Weisbender, Eric
Sent: Tuesday, June 24, 2014 8:10 AM
To: [email protected]<mailto:[email protected]>
Subject: [mapserver-users] FEATUREQUERY with SLAYER

Hello List,

I was wondering if there is an example of how to use FEATUREQUERY with SLAYER 
somewhere that I could reference for a project I am working on where I need to 
query features that intersect another feature.

Thanks
EW

_______________________________________________
mapserver-users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Reply via email to