-
Book Overview & Buying
-
Table Of Contents
ArcGIS for Desktop Cookbook
By :
Subtypes are properties of feature classes or non-spatial tables. The subtypes gather the features from a feature class or records from a non-spatial table that share the same attribute values using an attribute field. The attribute field that groups the features must be of the data type Short or Long integer, and it will be named the subtype field. A feature class can have only one subtype field. You can assign different behaviors to individual subtypes from a feature class/table. Generally speaking, the behavior is defined by the actions or characteristics of features in a geodatabase. A subtype has a code and a description. After you have defined the subtypes for a subtype field, you can change everything related to a subtype: change the value or description of code, add more codes, and delete code. The subtypes help you in the geometry editing process and prevent errors when editing feature attribute values. The subtypes maintain the integrity in a geodatabase.
You will continue to work with geodatabase schema by grouping features from the feature classes that you created in the previous Creating a feature class recipe. The integer subtype fields are the following: BD for Buildings, HType for Watercourse and WatercourseL, and CAT for LandUse.
Follow these steps to define subtypes using the context menu in ArcCatalog:
<drive>:\PacktPublishing\Data\MyGeodatabase\ Topo5k.gdb\Buildings.Buildings feature class, and navigate to Properties | Fields. You will define five subtypes for the BD attribute field. Select the Subtypes tab in the Feature Class Properties window. For Subtype Field, select the drop-down arrow and choose BD. In the Subtypes section, you have a default subtype with Code with the value 0 and Description with the value New Subtype. Change Description of the first subtype by typing Unknown.|
Code |
Description |
Code |
Description |
|---|---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|

Watercourse feature class, and choose Properties | Fields. Select the Subtypes tab in the Feature Class Properties window. You will define five subtypes for the HType attribute field. For Subtype Field select the drop-down arrow, choose HType, and add the following subtypes:|
Code |
Description |
Code |
Description |
|---|---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
Category) attribute field and the following subtypes:|
Code |
Description |
Code |
Description |
|---|---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The subtypes will help you to edit feature geometry and attribute fields faster. The default subtype is used as the default edit target for the Watercourse feature class when you start an edit session in ArcMap. In the Feature Class Properties dialog, you can add more subtypes for the BD attribute field, and you can delete a subtype or change Code and Description.
If you delete all code, your feature class will not have subtypes anymore, and all rules and behaviors related to subtypes will be corrupt or lost for the feature class.
Sometimes, when you are establishing codes and descriptions for a subtype field, it is impossible to anticipate correctly all possible values. It is good practice to add code that covers all unforeseen values: Code: 42 and Description: Other terrains. Another good practice is to add code that refers to the situation in which you know the values for all other attribute fields, but you are not sure about the subtype, and it will be defined later: Code: 0 and Description: Unknown.
Change the font size
Change margin width
Change background colour