I would like to be able to use a database connection to get workspace properties from Describe. Using Pro 3.1.3, accessing any of the workspace properties everything results in
OSError: "CIMDATA=<CIMStandardDataConnection xsi:type=...rest of connection string" does not exist
If I'm building paths to layers and tables in a script, I sometimes use Describe to get workspace information from one layer to build another. It's also helpful in debugging.
Here's a question discussion for reference.
Thank you for submitting your idea to describe connection strings using ArcPy's Describe methods. We appreciate your suggestion and the time you took to provide detailed feedback. ArcPy Describe is designed to work with data sources (direct paths to data) and ArcPy objects, but not with arbitrary strings. Dealing with arbitrary strings would add significant overhead. To get the description of a database connection, please continue using the result of Create Database Connection (Data Management)—ArcGIS Pro | Documentation or an existing .sde file. After careful consideration, we regret to inform you that we will not be implementing this idea at this time.
Thank you again for your contribution and understanding.
@HannesZiegler
I understand why this idea was closed, but I think you might consider to add the ability to use a connection string with the arcpy.management.CreateDatabaseConnection method. Otherwise, I dont understand what could be the utility of the connection string at all. I dont find any documentation about how to use a connection string and many arcpy function I have try juste does not works with connection string.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.