We are running an ArcGIS 10.0 geoprocessing script written in Python that (as part of many steps above & below) runs the Near tool.

Both the input and output datasets (shapefiles & personal geodatabase, respectively) are on a network drive, in the same projection, and we are not using a search distance (which by default = infinity, I believe). When we run the near command, sometime it successfully runs to completion and sometimes (usually) it only partially works.

When it partially works (but runs to completion), the results typically have anywhere from 1/4 to 1/2 of the features with a NEAR_DIST value = -1 (and it is always the top portion of the records, as sorted by the OID). In these cases, it also takes forever to process the top records, sometimes going from full success runs in 20 seconds to partial success runs in 1.5 hours.

Has anyone else experienced this kind of issue? Any suggestions on WHY the issue is occurring or HOW to fix the issue?

  • How many records are we talking here?
    – nagytech
    Commented Aug 10, 2012 at 0:43
  • In my most recent failed run, it was 254 points (shapefile) compared to 102 polygons (personal gdb). Of the 254 points, the top 139 were returned with -1. Commented Aug 10, 2012 at 14:24
  • 1
    Is the GDB perhaps on a network drive?
    – nagytech
    Commented Aug 11, 2012 at 2:52
  • @Geoist - Yes, the geodatabase and shapefiles are both on a network drive! Is this a known issue? Commented Aug 13, 2012 at 15:51
  • 2
    From personal experience I've noted that networked datasets can impede the speed of processing. So, it's not so much a known issue as it is a limitation of the computing environment. It may not be what's causing your particular issue, but it may be worth working on a local copy to see what happens.
    – nagytech
    Commented Aug 13, 2012 at 22:16

2 Answers 2


I'm going to credit @Geoist with the answer to this question, based on his comment above (NOTE: if you repost your comments as an answer, I will give you the "accepted mark").

As it turns out, the issue was in trying to run the NEAR analysis against the personal geodatabase on a network drive. As soon as I changed the source to an ArcSDE or file on the local drive, NEAR finally started completing 1) correctly to completion and 2) quickly.

My recommendation based on these findings is simply this: don't run GP processes over the network.

  • From my experience same issue happens if you run near analysis consecutively on the same dataset. First analysis returns the right data, but when I rerun it I get -1. The fix is just to restart ArcGIS. This was happening in ArcGIS 10.0 not sure if it's fixed now.
    – jareks
    Commented Aug 14, 2013 at 9:57

I've experienced same issues with near as Ryan described. In my case providing some kind of search radius resolved the situation.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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