arcgis online question

238
1
11-05-2023 08:02 PM
lenenkash
New Contributor

I’m fairly new to arcgis online. I have an account through my institution, and I’ve found a particular dataset that I’m interested in using for analysis on the arcgis REST server linked in the post.

My goal is to get the raw data for this map and upload it to my local arcmap session. I can upload is as a layer through an online connection but can’t use any commands on it. I can also view it on the arcgis online viewer, but it won’t let me download it. https://xender.vip/ 

My question is: is anyone familiar with the workflow needed to get the raw data as a shapefile, raster, or JSON file that I can save to my machine and upload to a local arcmap session?

Do I need to set up a python script or use QGIS to do this?

Thanks!

0 Kudos
1 Reply
TimF
by
New Contributor III

@lenenkash 

The following works for extracting vector FeatureService layers as GeoJSON from the ArcGIS REST Services Directory, when the standard download options aren't available.

At the foot of each layer page on the REST Services Directory ("/FeatureService/0", "/FeatureService/1" etc) there should be a 'Query' operation:

TimF_1-1699274962039.png

You can define your own query, but when I'm after everything I query for all OIDs >= 0 and include all fields. Change the format to GeoJSON and execute the 'GET' query. The results can be copied into a notepad and file extension changed to .geojson. Not a neat process, but works for one-offs.

TimF_2-1699275026671.pngTimF_3-1699275050727.png

Note: The query will only return records up to the maximum specified by the layer (MaxRecordCount) e.g., if it's 1,000 and I know there are 1,250 features - the query above will only return the first 1,000. I would need to perform another query with different search terms to get the last 250. The best query for this type of pagination would depend on the dataset itself, as OID will be less reliable - it may have jumps, so record 1,001 may not be OID 1001 etc.

This will only work for vector datasets - and my experience so far is only with FeatureServices, specifically. It may work with MapService layers, but I don't know for sure. I haven't had to extract rasters, but pretty sure there isn't an equivalent workflow like this for them.

Hope that helps.

0 Kudos