How To: Create a domain from the existing values in a table
A domain is a declaration of acceptable attribute values. Using domains helps ensure data integrity by limiting the choice of values for a particular field. In some cases, the values are pre-defined in a table and users want to set the values to a domain so that only the values within the domain are valid for the field.
The instructions provided describe how to create a domain from the existing values in a table.
1. Use the Summary Statistics tool to calculate the summary statistics for the field in the feature class.
Note: Ignore if the Error 000800 is displayed.
- In the Catalog window, navigate to System Toolboxes > Analysis Tools > Statistics > Summary Statistics.
- Select the feature class as the input table.
- Select the output table location.
- Select the required field as the statistics field.
- Click the field under the Statistics Type column, and select FIRST from the drop-down list.
- Select the same field as the case field.
- Click OK. A new table is created.
Note: Leave Domain Name, Domain Description, and Update Option at default values.
- In the Catalog window, navigate to System Toolboxes > Data Management Tools > Domains > Domain To Table.
- Select the output from the Summary Statistics tool as the input table.
- Select the same field used in the Summary Statistics tool as the code field.
- Select the same field as the description field.
- Select the file geodatabase as the input workspace.
- Click OK.
- In the Catalog window, right-click the feature class to which the domain is assigned in the file geodatabase, and click Properties.
- Click the Fields tab.
- Select the field, click the empty field next to Domain, and select the domain from the drop-down list.
- Click OK.
6. Open the attribute table of the feature layer, and click the field which the coded value domain is set. The drop-down list is displayed under the field.
- ArcGIS Help: Summary Statistics
- ArcGIS Help: Table To Domain
- ArcGIS Help: A quick tour of attribute domains