I have recently upgraded to ArcGIS Server 10.1 SP1. Since making the switch, I am getting a lot of inconsistent errors, specifically performing queries against a map service's REST API with the Javascript API.

I say inconsistent because an identical query will sometimes work, and other times I get an 'unable to complete operation' error. The queries are extremely simple, for example the where clause is "COUNTRY_ID = 2", and I am positive its not the where clause because it always worked coming from ArcGIS Server 10.0.

Testing the query in the REST page directly from the services directory yields the same result. My result alternates between success and error - query 1: success, query 2: error, query 3: success, query 4: error.

Has anyone experienced something similar?

UPDATE: From info I found in this post, I found that making POST requests resolves my issues.

4 Answers 4


Absolutely, you've hit the annoying bug NIM086349 in 10.1 that when you issue the exact same GET request / QueryTask to ArcGIS Server, it fails on alternate requests. Looks like it is fixed for SP2. @Derek Swingley who works for Esri pointed this out. NIM086349 http://forums.arcgis.com/threads/72894-Etags-and-Intermittent-QueryTask-Server-Errors

  • Thanks for the link. Seems like a pretty damn big bug to let go until SP2...
    – user890
    Feb 22, 2013 at 1:26
  • I agree -- I don't know how it was missed in their testing. As a developer all I do is test the same data over and over again -- you'd think they'd notice every other query failing. That said, if you have automated tests that don't keep a cache or clear the cache before each run, it might explain because I think the problem actually has to do with the ETAGS/caching on the request/response being fouled up. It would be an interesting to see what happens if the If-None-Match was stripped out of the header and repeatedly sent. en.wikipedia.org/wiki/HTTP_ETag
    – awesomo
    Feb 22, 2013 at 1:59
  • The bug says that it was introduced in 10.1 SP1, and is not in 10.1 final. There was a QFE (patch) so if you have to have a solution sooner than 10.2 (previously 10.1 SP2), call technical support or your regional distributor.
    – mkennedy
    Feb 22, 2013 at 17:35
  • I don't see a specific patch posted for this -- are you saying you could call support and they'll send it you? support.esri.com/en/downloads/patches-servicepacks/…
    – awesomo
    Feb 22, 2013 at 19:59
  • How to get to get ArcGIS 10.1 SP2? any link? perhaps contacting support center?
    – KDot1254
    Jan 7, 2014 at 14:31

Please refer the following link: They have suggested a workaround.


Regards BinnyN

  • 1
    Hi! Welcome to GIS.se! I'm not sure of the utility of your answer. The workaround that you have posted, is already present in the forum thread linked in the accepted answer. Am I missing something? Is there something new in your answer? May 9, 2013 at 6:52

Option 1:

Try republishing the service. I ran into this error when copying over a new mxd file to the server without publishing it.

Option 2:

Try the unique timestamp workaround already referenced by BinnyN. Below is the code:

var uniqueTimestamp = (new Date()).getTime();    
query.where += " AND " + uniqueTimestamp + "=" + dirty;

After changing to SDEBINARY geometry storage from SQL Geometry on SQL Server 2012, the problem disappeared for me. Hope someone finds this useful!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.