Hi Mike,
I am working on a Javascript application where I have a MSD published on ArcGIS server and I am using the URL from it's REST services. I am trying to select census block points that fall within a defined buffer distance and get a summary of number of blocks and housing units. I have it working but I am not getting consistent or accurate results, especially as the number of selected features increase.
I keep getting this unresponsive script error, and when I click on continue, it just keeps going or gives an inaccurate number, nothing close to actual number of blocks that fall within the buffer.
It will be great if you can help to fix this problem.
Thanks
Sorry, I don't really have the ability to tell you why you are seeing what you are. How are you generating the buffer? Are you querying features from the service? From your screenshot, it looks like you have over 10,000 blocks. Are you executing a query to the server to get those features? If so, you may be experiencing timeouts. The server probably can't handle the load.
Thanks,
Mike
Hi Mike,
I am working on a Javascript application where I have a MSD published on ArcGIS server and I am using the URL from it's REST services. I am trying to select census block points that fall within a defined buffer distance and get a summary of number of blocks and housing units. I have it working but I am not getting consistent or accurate results, especially as the number of selected features increase, either I get the unresponsive script message and when I say continue, I get results that do not match the number of blocks selected within the same buffer distance, around the same block point in ArcMap.
I have the buffer circle set like this:
circleBuffer = new Circle({ center: mapPoint, geodesic: true, radius: radius, radiusUnit: "esriMiles" });.
I tried with changing, mode: FeatureLayer.MODE_AUTO, to ONDEMAND and SELECTION but still no difference in results. Is there some limit on how many features can be returned by the server, in the service editor while publishing has a parameter "maximum number of record returned by the server" which is set by default to 1000?, but when I change that to 2000 or higher I start getting this script error.
I have attached the JS file for the application, if you can suggest any other way to build my query so I can get better results, it will be a great help.
Thanks!
Sorry, I'm not a coder. My sense is that you're overloading the server and it's not able to return all the features to you. You might actually be passing a lot of data between client and server, depending on the complexity of the features. For instance, how many vertices are there per feature? I'm guessing the server times out. Do you own the server? You might be able to check the server logs to see if there are any error messages.
Mike
Mike,
As for complexity of the features, it just point data, so no vertices and yes it is published on our ArcGIS server and I can ask the server administrator to look at the server logs.
Do you have any suggestions who or where I can get help with the code, so I can make changes to the query to improve result and performance.
Thanks.