Select to view content in your preferred language

How does one search for Web Map in an ArcGIS Portal?

3021
9
Jump to solution
07-11-2016 12:07 PM
DavidElies
Deactivated User

When I use esri/arcgis/Portal to search for PortalItems, I specifically want to find Web Maps.  When I try to provide "q":"Web Map", I get web mapping applications galore, and find no actual web maps.  Is there a better way to discover web maps in Portal?

0 Kudos
1 Solution

Accepted Solutions
RobertScheitlin__GISP
MVP Emeritus

David,

  The double quotes Kelly had are required.

Here is the full string:

q:'type:("web map" AND -"web mapping applications")'

View solution in original post

9 Replies
RobertScheitlin__GISP
MVP Emeritus

David,

  This is what you should use:

q=type:"web map"&t=content&focus=maps

DavidElies
Deactivated User

Thanks for your response!

It looks like you've provided parameters for some sort of REST call.  I may have to go that route, but I am trying to use the esri/arcgis/Portal class provided in the Javascript API.  The "q" I was referring to was the parameter to the queryItems method on that Portal object. There don't appear to be "t" or "focus" parameters to that particular method.

0 Kudos
RobertScheitlin__GISP
MVP Emeritus

David,

Adding this to the q: parameter for the portal object seems to work for me:

'type:"web map"&t=content&focus=maps'

DavidElies
Deactivated User

Sorry, I didn't realize I could do that.  thanks!

0 Kudos
DavidElies
Deactivated User

I believe I spoke too soon.  I actually do get back results for Web Maps, but I still get Web Mapping Applications which I do not want.

0 Kudos
KellyHutchins
Esri Frequent Contributor

Try adding the following to filter out Web Mapping Applications

-type: "Web Mapping Application"

DavidElies
Deactivated User

Thanks for your help.  It doesn't seem to work.  Depending on how I try this

-type:Web Mapping Application

type:-Web Mapping Application

type: -Web -Mapping -Application

I can't make it filter out the web mapping applications while leaving the web maps.  I seem to be missing the way that these filters actually work, since it appears to give me arbitrary results. Either it filters everything, (no results) or greatly limits the returned items, but mostly leaves out the web maps.

The documentation for the REST API is not clear on how AND, OR, +, -, NOT, wildcards, etc. work. It says that the default is AND, but this does not seem to be the case, since it seems to find the word "map" and then includes anything that includes the single word, not just those that contain "web map".  Or, maybe it includes automatic wildcards?  Since the search term "map" finds "mapping".  Possibly it searches all default fields instead of just the field I specify ("type", in this case).  Can you shed some light on how this search actually works (or how it's supposed to work, at least)?

0 Kudos
RobertScheitlin__GISP
MVP Emeritus

David,

  The double quotes Kelly had are required.

Here is the full string:

q:'type:("web map" AND -"web mapping applications")'

DavidElies
Deactivated User

Sorry, I guess I'm not good at picking up the little details.  This did work for me!

0 Kudos