I was trying to determine the best way to standardize my attribute table.

I thought I would use a coded value domain but I am unable to do that without creating a subtype first. I don't understand this but figured I would just create a blank subtype to create the coded value domain. The trouble is that subtypes require a Long integer field which, when exported to a shapefile, are meaningless, just a number in a field.

Consequently, I decided to just create a new subtype properly. I attempted to delete the before mentioned domain and I get the error:

Failed to delete a domain from the database. The domain is used by an attribute rule.

I removed that "attribute rule" but it still will not delete.

The idea of subtypes and domains are a great idea but this locking problem and the subtype field requirement of being an integer rather than String is an issue for me.

For now I will just create the subtype and leave the domain.

  • As it stands there is no question mark in your question body so what you are asking is difficult to discern. There is a question mark in the title but that does not seem to be a summary of the body. – PolyGeo Oct 29 '18 at 20:22

Subtypes and Domains are for Geodatabases only - exporting to shapefiles will not work (they are old tech compared to geodatabases)

subtypes categorize your data.

domains constrain input information to validate data entry.

Apply coded or ranged domains to features, enabling you to constrain input information to a valid set of values. For example, in a water distribution network, the subtype water mains could have a coded domain for building materials restricting them to be made of cast iron, ductile iron, or copper.

Range domains—A range domain specifies a valid range of values for a numeric attribute

Coded domains—A coded value domain can apply to any type of attribute—text, numeric, date, and so on. Coded value domains specify a valid set of values for an attribute. (you want these)



You shouldn't need to create a subtype in order to use a coded value domain. It's easy to be fooled by the domain properties dialog as it doesn't have any indicators that the rows in the Domain Properties sections are actually pick lists and it's only the default which is long integer.

domain properties showing drop down field type

I just verified domains without subtypes works (in v10) with:

  1. Start ArcCatalog
  2. create new file gdb, create empty feature class
  3. add a few text fields to the FC
  4. goto fgdb properties, select Domain tab, enter a name in first row
  5. Select Field Type of text, then Domain Type of Coded Values, add a couple of values and descriptions, save
  6. Select FC > Properties > Fields and then apply the coded value domain in the Field Properties section.

Use the same dialog as in #6 to remove a domain from a feature class, and then you can delete the domain from the gdb. If the geodatabase doesn't have any attribute domains defined the domain row of this dialog remains hidden. This method is also covered here.

The same can be accomplished using the Create Domain geoprocessing tool.


Use the "Remove Domain from Field" tool (Data Management > Domains) to remove the attribute rule, allowing you to delete the domain.

If you want to export a domain to a shapefile, you have to go through a six step process.

  1. Export the feature class to shapefile.
  2. Add a new field of the appropriate type to the shapefile (e.g. String if the domain codes into a string).
  3. Export the domain table using "Domain to Table" (Data Management > Domains).
  4. Join the exported domain table to the shapefile's attribute table using the long integer code field in the shapefile joined to the code field on the domain table
  5. Calculate value on the added field, using the description field from the domain table.
  6. Remove the join. You can optionally delete the long integer code field in the shapefile too.

Values residing at attribute Domain can be shared by FCs, their subtypes, tables etc i.e. across the gdb. But Subtype as mentioned is used for categorize a particular FC under observation and for that FC use only; e.g. Road may have National Highway, Feeder Road, Car track or even Footpath as well..! It is better to make subtype of above for Road FC. However the width or other attributes which you think those can be shared across the gdb can be placed in Domain.

Not the answer you're looking for? Browse other questions tagged or ask your own question.