Select to view content in your preferred language

Check if Enterprise Geodatabase is reconcilied in ArcPy

2093
10
01-21-2020 02:01 AM
AlbertoLópez
Occasional Contributor

Hi;

In a python/arcpy script I have to do a compress database and a regenerate index. I don't have to do a reconcilied version.

But previously I have to validate if users have reconcilied the data in the default version of the enterprise database.

Is there any way to do this with ArcPy?. Maybe doing a query to the sde.version table or other table. But I do not how.

Thanks. Greetings.

0 Kudos
10 Replies
JoshuaBixby
MVP Esteemed Contributor

The Geodatabase compression—Help | ArcGIS Desktop states:

It may not always be possible to reconcile, post, delete versions, and disconnect all users before compressing. For instance, if you are tracking history using versions or need to maintain design versions for a project, the historic and design versions hold a state within the state tree; therefore, these states are not removed during compression of the geodatabase. You can successfully compress without doing all these steps, and you will still see performance improvements.

Don't let the "best workflow" get in the way of a "good workflow."  Ideally, a geodatabase would be compressed to State 0 every time, but that can be a huge undertaking when an enterprise geodatabase has even a modest number of users.  If regular, partial compressions aren't doing enough; you can always reconcile and post all the versions as the geodatabase administrator, but you would need to make assumptions about how to handle conflicts.