How to update connection properties to in memory source

01-25-2021 11:58 AM
by Anonymous User
Not applicable

ArcGIS Pro 2.6 and Python 3.6

I am creating a custom Map Series and have hit a bit of a roadblock. I originally was writing all data to a local FGDB, but I'm looking for ways to improve performance.

I switched to using `memory` as this appeared to be a viable option. However, I cannot update the source of the layers inside the map document (.aprx). I have been able to do this successfully with local files (not using the Python CIM), but I am stumped trying to do it with memory objects. Is it even possible?

Here is the layer as it currently exists in my map:


And here is what I'm trying (though I have tried a few things with no luck).





lyrCIM = l.getDefinition("V2")

dc = lyrCIM.featureTable.dataConnection

dc.workspaceFactory = "InMemoryDB"
dc.datasetType = "esriDTAny"
dc.workspaceConnectionString = r"memory//" +



Well, maybe it is working?





0 Kudos
2 Replies
MVP Esteemed Contributor

Considerations when using the in_memory workspace—ArcGIS Pro | Documentation

The in_memory workspace does not support geodatabase elements such as subtypes, domains, representations, topologies, geometric networks, network datasets, or feature datasets.

... sort of retired...
by Anonymous User
Not applicable

I am trying to use the newer `memory` workspace. Seems it has the same limitation and I missed it.

This was what caught my eye:

To display memory-based data in an ArcGIS Pro map, you can use the memory workspace.

0 Kudos