How To: Permanently reorder fields in a geodatabase feature class using the X-Ray for ArcCatalog add-in when working with non-simple feature classes
In some instances, when performing updates to a geodatabase schema, users may want to customize the attribute information by listing fields of a feature class in a different order. Installing the X-Ray for ArcCatalog add-in provides the capability to permanently reorder fields in a geodatabase.
Note: The needed version of the X-Ray for ArcCatalog add-in is specific to the version of Microsoft Excel used. If using Microsoft Excel 2007 or 2010, install X-Ray for ArcCatalog (ArcGIS 10.1 Standard or Advanced). For Microsoft Excel 2013, install the updated version of the add-in, which supports ArcCatalog 10.2 to 10.4 (Standard or Advanced).
Use the Reorder Fields tool from the Tools drop-down menu in the X-Ray window to reorder fields of a simple feature class. If the feature class has pre-existing data, appending the data is not required since the tool only modifies the schema of the geodatabase.
However, the Reorder Fields tool is not designed to work with non-simple feature classes, such as feature classes in a geometric network, feature classes in a relationship with messaging, and feature classes that have feature-linked annotation. To reorder fields in non-simple feature classes with the X-Ray for ArcCatalog add-in, use the workaround provided below.
Warning: The workaround provided below does not preserve existing data in feature classes when reordering fields. Additionally, any existing relationship classes are not maintained in the output dataset containing the reordered fields feature class. It is recommended to copy the dataset to a new geodatabase, and use the new geodatabase prior to reordering fields so that any changes made are not applied to the original geodatabase.
- In the Catalog Tree, create a new XML document. Right-click the folder to store the XML file, and select New > XML Document.
- In the X-Ray window, add the geodatabase (where the feature class to reorder is stored) and the XML document created in Step 1 in the Geodatabase and XML Workspace Document fields respectively.
- Go to X-Ray > Export from Geodatabase to export the feature class schema to the XML Workspace document.
Note: Alternatively, click to export the feature class schema to the XML Workspace document.
- With the XML Workspace document open, click Edit > Datasets. This launches an Excel document containing the geodatabase tables to perform updates and changes to the feature class schema.
- Arrange the fields in the desired order, and save the Excel workbook.
- Ensure the corresponding XML Workspace document is selected in X-Ray, and click to save the edits to the selected XML Workspace document.
- Create a new file geodatabase, and click to import the edited XML Workspace document into the geodatabase to update the geodatabase schema with the new field order.
- ArcGIS Help: Geodatabase XML
- ArcGIS Resources: Getting Started with the Local Government Information Model
- FAQ: Is it possible to change field order in an attribute table?
- HowTo: Change the order of field names in an attribute table
- ArcGIS Ideas: ArcGIS should allow the ability to permanently reorder fields in a table
- ArcGIS Help: Building a geometric network from existing simple feature classes
- ArcGIS Help: Relationship class properties