I just upgraded by Enterprise Geodatabases from SQL Server 2005 to SQL Server 2014 and now I am getting the "Failed to compress the database. Underlying DBMS error [dbo.DEFAULT]" error message. From looking at other people's questions, it looks like I need to recreate the spatial indexes on all my feature classes. My question is:
Is there a tool or script that will recreate all of the feature classes in my geodatabase at once? So I don't have to do it one at a time?
Conceptually you can use the RebuildIndexes_management() in a loop. Something like this: (untested!)
arcpy.env.workspace = r'X:\use\path\of\connection\file
fcList = arcpy.ListFeatureClasses()
for fc in fcList: