|
DOC
|
@BrianShepard thank you for posting your code snippet. I was missing the .result() for the add method. I've updated the script and zip file on this page.
... View more
12-05-2024
02:31 PM
|
0
|
0
|
17183
|
|
DOC
|
@ChristopherPouliot I would recommend migrating your entire Enterprise using the webgisdr instead:
https://www.esri.com/arcgis-blog/products/arcgis-enterprise/administration/migrate-to-a-new-machine-in-arcgis-enterprise-two/
If the DNS is going to change in the new instance, starting at 11.4, there are built-in tools to update the Organization URL:
https://enterprise.arcgis.com/en/portal/latest/administer/windows/update-the-organization-url.htm
... View more
12-05-2024
01:35 PM
|
0
|
0
|
35746
|
|
DOC
|
@BrianShepard good find. I think there are still some issues. The help states this should return arcgis.gis.Item, but during my testing it's returning concurrent.futures._base.Future. Which will cause the append operation to fail:
JakeSkinner_0-1733259882171.png
... View more
12-03-2024
01:05 PM
|
0
|
0
|
17266
|
|
DOC
|
@BrianShepard @DJB that help document is helpful and looks like the new way forward is to use .add from the Folders method, however, I could not get this to work:
JakeSkinner_0-1733256980369.png
I even tried the sample code here and received the same error.
... View more
12-03-2024
12:17 PM
|
0
|
0
|
17292
|
|
POST
|
@WhitneyWeber in the following Migrate Content tools is a Copy Hosted Feature Services tool. Try this tool and see if it works.
... View more
12-02-2024
09:14 AM
|
0
|
0
|
964
|
|
DOC
|
@ModernElectric try the latest script here. I updated the code to re-enable sync on the feature service if it was previously enabled:
JakeSkinner_0-1733150511656.png
... View more
12-02-2024
06:42 AM
|
0
|
0
|
17360
|
|
POST
|
@OrvilleMcLean are you able to test any other server that has ArcGIS Pro or the ArcGIS API for Python installed?
... View more
12-02-2024
05:23 AM
|
0
|
0
|
3980
|
|
POST
|
@ChallagundlaSindhuraITS no, not without an Admin account.
... View more
12-02-2024
05:17 AM
|
0
|
0
|
324
|
|
DOC
|
@ModernElectric,
The script should disable and re-enable Sync in this portion of the script:
JakeSkinner_0-1732738178713.png
Sounds like this is not happening on your end?
... View more
11-27-2024
12:33 PM
|
0
|
0
|
17420
|
|
POST
|
1. Does this occur on every web map?
2. What version of the api are you running?
JakeSkinner_0-1732655292297.png
... View more
11-26-2024
01:08 PM
|
0
|
1
|
4029
|
|
POST
|
@OrvilleMcLean I was able to get the below to work:
import arcpy
from arcgis.gis import GIS
from arcgis.map import Map
# Variables
username = 'jskinner_rats'
password = '*********'
webMapID = '50223959653f40b8bb097bd0fda7994a'
outputGDB = r'C:\temp\python\test.gdb'
# Environment Variables
arcpy.env.overwriteOutput = True
# Connect to AGOL
gis = GIS('https://www.arcgis.com', username, password)
arcpy.SignInToPortal('https://www.arcgis.com', username, password)
wmItem = gis.content.get(webMapID)
webmap = Map(wmItem)
layers = webmap.content.layers
tables = webmap.content.tables
# Export Feature Services/Tables
if len(layers) > 0:
for layer in layers:
print(f"Exporting {layer}")
arcpy.ExportFeatures_conversion(layer.url, outputGDB + '\\' + layer.url.split('/')[-3])
if len(tables) > 0:
for table in tables:
print(f"Exporting {table}")
arcpy.ExportTable_conversion(table.url, outputGDB + '\\' + table.url.split('/')[-3])
... View more
11-26-2024
11:30 AM
|
0
|
2
|
4032
|
|
POST
|
@DavidColey try changing the group name to the group ID:
org_group = ["Planning Layers Group"]
Ex:
org_group = ['80d1821b9af64b9b9fd81dc0d4c8d991']
... View more
11-26-2024
09:25 AM
|
0
|
0
|
2337
|
|
POST
|
Hi @OrvilleMcLean,
I've used the Web Map's JSON before to get the layers/tables. Below is a snippet your could use to download feature services/hosted tables from a web map.
import arcpy
from arcgis.gis import GIS
# Variables
username = 'jskinner_rats'
password = '********'
webMapID = '50223959653f40b8bb097bd0fda7994a'
outputGDB = r'C:\temp\python\test.gdb'
# Environment Variables
arcpy.env.overwriteOutput = True
# Connect to AGOL
gis = GIS('https://www.arcgis.com', username, password)
arcpy.SignInToPortal('https://www.arcgis.com', username, password)
# Get feature service and table URLs
operationalLayers = []
operationalTables = []
webMap = gis.content.get(webMapID)
webMapJSON = webMap.get_data(try_json=True)
try:
for layer in webMapJSON['operationalLayers']:
if layer['layerType'] == 'GroupLayer':
for groupLyr in layer['layers']:
operationalLayers.append(groupLyr['url'])
else:
operationalLayers.append(layer['url'])
for table in webMapJSON['tables']:
operationalTables.append(table['url'])
except KeyError:
pass
# Export Feature Services/Tables
if len(operationalLayers) > 0:
for layer in operationalLayers:
print(f"Exporting {layer}")
arcpy.ExportFeatures_conversion(layer, outputGDB + '\\' + layer.split('/')[-3])
if len(operationalTables) > 0:
for table in operationalTables:
print(f"Exporting {table}")
arcpy.ExportTable_conversion(table, outputGDB + '\\' + table.split('/')[-3])
... View more
11-26-2024
09:19 AM
|
0
|
4
|
4050
|
|
POST
|
Are you able to export the feature service to a File Geodatabase using the item details page?
... View more
11-26-2024
05:32 AM
|
0
|
1
|
1461
|
|
POST
|
Hi @CanDAGDELEN1, give the Copy Hosted Feature Services tool in this toolset a shot.
... View more
11-26-2024
04:38 AM
|
0
|
1
|
1488
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 07-08-2026 12:27 PM | |
| 4 | 05-07-2020 05:14 PM | |
| 1 | 03-25-2026 04:16 AM | |
| 1 | 03-16-2026 01:00 PM | |
| 1 | 12-22-2025 10:39 AM |
| Online Status |
Offline
|
| Date Last Visited |
Tuesday
|