|
IDEA
|
It would be very helpful to have the option of specifying field data types when using the Excel to Table geoprocessing tool in Pro. Sometimes the field types don't get assigned in the way you want in Excel, and then that carries over to Pro. Then you have to do annoying workarounds like adding and calculating a new field. Thanks!
... View more
06-29-2023
11:30 AM
|
9
|
1
|
763
|
|
POST
|
Hello, unfortunately I don't have any idea why this would be happening! That is weird that it's only happening with the Arabic one. I hope you can find a solution!
... View more
06-19-2023
09:25 AM
|
0
|
0
|
5436
|
|
POST
|
Thank you, Robert! Another person tried creating the replica, and it worked. It's a mystery! I'm all set now.
... View more
06-15-2023
11:24 AM
|
0
|
1
|
894
|
|
POST
|
Hello, I am using the Create Replica tool in ArcGIS Pro, version 3.0.3, and I got error 002829 "Can't ConstructUnion on a point." Why?? this does not make any sense to me, because I am creating a replica, not doing anything with a union. Any ideas? I am trying to create a replica from one Feature Dataset to another Feature Dataset in the same database. That might seem weird; it's for testing. The prod environment has replicas from one database to another, but the dev environment only has one database, so I'm trying to approximate prod in dev the best I can. The replica consists of only one feature class, a point feature class. Parameters: one way, parent to child, simple model I'm using what I think is the right database service account to run Pro to create the replica. Thank you to anyone who has ideas!
... View more
06-13-2023
04:17 PM
|
0
|
3
|
1130
|
|
POST
|
I got an answer! I worked with Esri representatives and it took some time and digging, but they ultimately told me that you need to be connected to the Esri License Manager, like via ArcGIS Pro on the machine, in order to use geoprocessing tools like Rebuild Address Locator in Python. This explains why I was able to run the function in a Pro Notebook, and then later in Windows Command Prompt using the Python .exe that comes with Pro, but not the Python .exe that comes with ArcGIS Server. Side note - I was trying to run the script on an actual ArcGIS Server, rather than a PC or file server, because we needed to rebuild our address locators that are in our Public DMZ network. Internal network machines cannot access the DMZ servers for this purpose, so I was trying to run the script on the DMZ server using the Python .exe that comes with ArcGIS Server software (because Pro was not installed on that server, and regardless, that server can't access the license manager in order for Pro to work there). So the solution is to have Pro on the machine and connect to the license manager. If the machine cannot do that, which is the case for our DMZ servers, then you have to find a workaround. We might try rebuilding the locators on the internal network and then copying the files onto the DMZ server, or allowing the ability to have a shared folder on the DMZ server where the internal server can access the locator files. Esri previously told me that Server Python and Pro Python were equivalent, and I'm sure they have the same ingredients, but it would be nice if there was documentation somewhere that said you basically can't use arcpy via Server Python.
... View more
06-08-2023
03:09 PM
|
1
|
3
|
5457
|
|
POST
|
Hello! I know this post is old, but did you ever find a solution? I'm facing something similar. Thanks!
... View more
05-09-2023
08:51 AM
|
0
|
0
|
830
|
|
POST
|
Thanks for your reply. So far I am just running the script via Command Prompt by entering the Python exe path and the script file path. I have rebuilt the locators manually by running Pro as the account that I use to run the script in Command Prompt, and that works, so I think the account seems fine.
... View more
05-08-2023
10:15 AM
|
0
|
0
|
5538
|
|
POST
|
Hello! Did you ever find an answer to this problem? I know this post is extremely old, but I recently ran into a similar situation.
... View more
05-04-2023
05:26 PM
|
0
|
0
|
842
|
|
POST
|
I am trying to automate rebuilding address locators with a Python script. I am able to successfully rebuild the address locators manually in ArcGIS Pro with the Rebuild Address Locator geoprocessing tool. But I continually get "Error 000005: Could not open the address locator" when trying to rebuild them with the script. I've run out of ideas of things to check. In the documentation for Error 000005, it says: "This error can occur for one of the following reasons: A locator built with the Create Locator tool is the input to the Rebuild Address Locator tool and the reference data for the locator is stored in an enterprise geodatabase or is not accessible." Does this mean that, if you use those tools, the locator cannot use data from an enterprise geodatabase? It would be super helpful if someone could confirm that for me. I feel like that is what the documentation says, but I just find that hard to believe, because it seems like most people would be using data from an enterprise gdb!! I am. Here are the relevant parts of my script - can you see anything that should be changed?? import arcpy
arcpy.env.workspace = r'D:\MyFolder\Locators'
arcpy.geocoding.RebuildAddressLocator(r"D:\MyFolder\Locators\MY_LOCATOR")
# I also tried the above line with only the locator name as the argument ("MY_LOCATOR") Thank you!
... View more
05-04-2023
05:16 PM
|
0
|
8
|
5567
|
|
POST
|
Update - I figured it out. I submitted a help request to Esri, and they tested my code and it worked in their environment. So then I tried to drill deeper into possible issues other than the code itself. I eventually discovered that on our DMZ servers, the account that is running the script (i.e. the account being used to run software like IDLE, Command Prompt, Pro, etc.) has to be the account that enters the credentials - used as an argument for the Server object - into Windows Credential Manager. We are using Keyring to get the credentials from Windows Credential Manager in order to avoid hard-coding them in the script, which would be a security risk. The account I need to use to run the script is different from the account whose credentials have to be passed into the Server object. I ran Command Prompt as the account used to run the script, and in Command Prompt I used Python keyring to set_password for the credentials to be called in the Server object. It seems that in our server environment, an account cannot access credentials that someone else (a different account) entered into Windows Credential Manager. Now the script is able to stop and start services! This issue will probably only apply to a miniscule number of people out there, but it would be cool if this could help at least one other person!
... View more
02-22-2023
11:21 AM
|
1
|
0
|
2247
|
|
POST
|
Thank you for your reply! I believe that the GIS object cannot be used with standalone servers, only the Server object can. But I really appreciate your reply.
... View more
02-22-2023
11:13 AM
|
0
|
0
|
2248
|
|
POST
|
I am working on a standalone script that is supposed to stop a few geocoding services, then rebuild the address locators used in those services, then start the geocoding services. It is supposed to run on a standalone, non-federated ArcGIS Server (version 10.9.1) (the same server that the services were published to) in a DMZ server network. The script is running on the server itself because machines on my internal network cannot connect with the DMZ server in the ways that are needed for this script. I am using the ArcGIS API for Python to stop and start the services, and I based those parts of the script on sample code from Esri. The geocoding services were published on the ArcMap runtime, and today I created a Pro runtime geocoding service, and the script didn't stop that service either. I am running the script in Command Prompt and sometimes in IDLE. PROBLEM: The script does not stop the geocoding services, yet it moves through that part of the script without throwing an error. I can see in Server Manager online that the services are never stopped. It only hits an error when it tries to rebuild an address locator but can't do it because the geocoding service was not actually stopped first. I have run out of ideas of how to troubleshoot or fix this. I have double-checked everything I can think of to check - credentials, names and paths, etc. The credentials being used can indeed stop the services manually in Server Manager. Does anyone have any ideas? Here is the core of the code: import sys
import datetime
from arcgis.gis.server import Server # ArcGIS API for Python
import arcpy
import keyring
if __name__ == "__main__":
# Folder path where the locator is, not the service:
arcpy.env.workspace = r'D:\RootFolder\OtherFolder'
# Name of folder in the Server Manager where the locator lives:
folder_folder_name = 'MyFolder' # File Explorer folder name
ags_folder_name = 'MY_FOLDER' # ArcGIS Server Manager folder name
# Base URL of the ArcGIS Server where the service lives:
server_base_url = r'https://myserverbaseurl:port'
# Names of the locators (not services):
locator_name_list = ['LOCATOR_ROAD', 'LOCATOR_POINTS', 'LOCATOR_ADDR']
# Names of the geocoding services published to the server:
locservice1 = 'MY_FAV_SERVICE'
locservice2 = 'THE_OTHER_SERVICE'
username = keyring.get_password('name', 'user')
pw = keyring.get_password('other_name', 'password')
# Create an instance of a Server object in ArcGIS API for Python.
server = Server(url='{}/arcgis/admin'.format(server_base_url), username=username, password=pw)
# Access server content (ArcGIS API for Python)
cdir = server.content
# Instantiate the services as service objects
service1 = cdir.get(locservice1, folder=ags_folder_name)
service2 = cdir.get(locservice2, folder=ags_folder_name)
# TEST - this worked.
#print(service1.service.iteminformation)
#print(cdir) # This worked.
# Stop the geocoding services in order to next rebuild the locators
service1.service.stop()
service2.service.stop()
# Rebuild the locators.
for locator_name in locator_name_list:
print(locator_name)
arcpy.geocoding.RebuildAddressLocator(locator_name)
# Start the services after rebuilding. (ArcGIS API for Python)
service1.service.start()
service2.service.start()
... View more
01-25-2023
06:10 PM
|
1
|
3
|
2391
|
|
POST
|
Thank you so much! Whoops, it had not occurred to me to do something like that. It worked!
... View more
01-25-2023
12:37 PM
|
0
|
0
|
3253
|
|
POST
|
Please help... I have done so many google searches for this and... nothing. Whyyyy? What is the file/directory location or path of the ArcGIS API for Python, particularly on an ArcGIS Server? I am having extremely mysterious failure with a standalone script that is trying to use the API to stop services, so I want to find some way to check if the API really exists on this server where I'm running the script. Thank you!
... View more
01-25-2023
11:24 AM
|
0
|
4
|
3293
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 09-30-2025 03:01 PM | |
| 1 | 09-30-2025 05:42 PM | |
| 1 | 11-01-2023 11:39 AM | |
| 1 | 11-21-2024 04:21 PM | |
| 1 | 08-05-2025 12:29 PM |
| Online Status |
Offline
|
| Date Last Visited |
12-18-2025
12:06 PM
|