Question
It can happen that entire File Geodatabases (FGDB) or parts of them (Feature Classes) become corrupt. How can the affected parts be repaired?
Cause
Possible reasons for corrupt FGDB are:
- If edits to a feature class are not saved during an editing session
- If the editing session is interrupted by an application crash
- If a feature class is stored on a network drive and there is a connection fluctuation to the drive
- ...
Problem
The following symptoms can occur:
- Error opening the FGDB
- Error opening the feature class (FC)
- Editing errors (e.g., entries disappearing in the attribute table when sorting)
- Error in preview in ArcCatalog
- ...
Solution
The following options exist to solve such problems:
- Repair: https://desktop.arcgis.com/de/arcmap/10.3/manage-data/administer-file-gdbs/compact-file-and-personal-geodatabases.htm
- Compress / Decompress: https://desktop.arcgis.com/de/arcmap/10.3/manage-data/administer-file-gdbs/compress-file-geodatabase-data.htm
- Recover: https://desktop.arcgis.com/de/arcmap/10.3/tools/data-management-toolbox/how-recover-file-geodatabase-works.htm
- Copy the database to another data type (Personal Geodatabase, SQL Server, Oracle
If the above options do not bring improvement, the following option exists:
Option 1: FME
- Load the affected feature class using FME and write it into a new FGDB.
- Unlike ArcCatalog, FME does not abort when encountering corrupt features, but ignores them and continues with the other features.
- However, the ObjectID and GlobalID cannot be preserved during this export and will be changed. Therefore, ensure that the original ObjectID and GlobalID are written into new separate fields OID_TEMP and GLOBALID_TEMP.
Model: geodatabase_file2filegdb_Copy_ORI_ID.fmw
- Copy the feature class into a SQL Server database
- Directly overwrite the OBJECTID and GLOBALID in SQL Server Management Studio with the values from OID_TEMP and GLOBALID_TEMP, e.g.:
USE LEER ;
GO
UPDATE LEER_OWNER.AWK_ABWASSERKNOTEN
SET OBJECTID = OID_TEMP
WHERE 1=1
GO
- Copy the feature class back from the SQL Server database into the original FGDB.
Option 2: Model in ArcCatalog
See https://support.esri.com/en/Technical-Article/000021330
Model: Toolbox.tbx
As described for the FME method, the ObjectID and GlobalID are also changed here. Therefore, they must also be edited directly in SQL Server Management Studio afterwards.
Comments
0 comments
Article is closed for comments.