ArcGIS Server's Query - Returned w/ different records

694
4
Jump to solution
11-24-2014 09:26 AM
ShaningYu
Frequent Contributor

I tried 2 things:

1)  Run the code sourced from ESRI (see attached).  The query returned > 100 features and populated on the left pane's Grid.

2)  Go to the service site: http://trainingcloud.arcgis.com/arcgis/rest/services/Redlands_PointsOfInterest/MapServer/0, and run the query:   where:  NAME Like '%Redlands%'   Geometry Type:  Envelope   Out fields:  OBJECTID, NAME, Match_addr, TEL, TYPE   Spatialo relationship: Contains Or use the link  http://trainingcloud.arcgis.com/arcgis/rest/services/Redlands_PointsOfInterest/MapServer/0/query?whe... which results in only 12 records.

Tried several times with the same results on both cases.  Can someone explain why?  Thanks.

My Template

NameAddress
Created by J. Doe
0 Kudos
1 Solution

Accepted Solutions
RobertScheitlin__GISP
MVP Emeritus

Shaning,

    no it was not attached when I replied.

The issue is initially when you run the code the results contain all features that intersect the maps view extent and when you run your query you are only looking for features that have 'Redlands' in its name.

I think your confusion is that you are seeing 'Redlands' in the in the Match_addr of the initial 100+ results and are expecting to see the same when you query.  If you change your query to  this then you will see results similar to what you are when you initially run the app:

http://trainingcloud.arcgis.com/arcgis/rest/services/Redlands_PointsOfInterest/MapServer/0/query?whe...

View solution in original post

4 Replies
RobertScheitlin__GISP
MVP Emeritus

Shaning

Run the code sourced from ESRI

What code?

0 Kudos
ShaningYu
Frequent Contributor

Did you see the attached file? Thanks.

0 Kudos
RobertScheitlin__GISP
MVP Emeritus

Shaning,

    no it was not attached when I replied.

The issue is initially when you run the code the results contain all features that intersect the maps view extent and when you run your query you are only looking for features that have 'Redlands' in its name.

I think your confusion is that you are seeing 'Redlands' in the in the Match_addr of the initial 100+ results and are expecting to see the same when you query.  If you change your query to  this then you will see results similar to what you are when you initially run the app:

http://trainingcloud.arcgis.com/arcgis/rest/services/Redlands_PointsOfInterest/MapServer/0/query?whe...

ShaningYu
Frequent Contributor

Rob:  Thanks a lot.

0 Kudos