Subtypes in feature classes in a geodatabase in DB2

Subtypes are used to differentiate feature types within a feature class based on their default values, attribute domains, connectivity rules, and relationship rules. Subtypes are defined for a feature class, and only one field in the feature class can have subtypes defined for it.

Subtypes in ArcGIS Desktop

Since subtypes are defined for a feature class, you define and view subtypes in the Catalog window from the Feature Class Properties dialog box. Right-click the feature class, click Properties, then click the Subtypes tab to see the following dialog box:

Subtypes in the Catalog

This example shows subtypes applied to the TYPECODE field for the feature class, Laterals. You see the codes used for the subtypes, the descriptions (names) of the subtypes, and the default subtype for the TYPECODE field in the Laterals feature class.

Subtypes in an IBM DB2 database

Subtypes are stored in the DEFINITION column of the GDB_ITEMS table. They are a characteristic of their associated item (feature class or table).

Subtypes in an XML document

Subtypes appear in XML documents as part of the information for the feature class. They are grouped under a Subtypes tag. For the Laterals example, the subtype information in an XML document is as follows:

<Subtypes xsi:type="esri:ArrayOfSubtype">
  <Subtype xsi:type="esri:Subtype">
      <SubtypeName>Unknown</SubtypeName> 
      <SubtypeCode>0</SubtypeCode> 
    <FieldInfos xsi:type="esri:ArrayOfSubtypeFieldInfo">
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>H_CONFID</FieldName> 
          <DefaultValue xsi:type="xs:int">0</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>DIAMETER</FieldName> 
          <DomainName>LatDiameter</DomainName> 
          <DefaultValue xsi:type="xs:double">8</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>DEPTH_BURI</FieldName> 
          <DefaultValue xsi:type="xs:double">0</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>RECORDED_L</FieldName> 
          <DefaultValue xsi:type="xs:double">0</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>WNM_TYPE</FieldName> 
          <DefaultValue xsi:type="xs:string">WUNKNOWN</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>PWTYPE</FieldName> 
          <DefaultValue xsi:type="xs:string">WUNKNOWN</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>MATERIAL</FieldName> 
          <DomainName>Material</DomainName> 
          <DefaultValue xsi:type="xs:string">DI</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>TYPECODE</FieldName> 
          <DefaultValue xsi:type="xs:int">3</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>ENABLED</FieldName> 
          <DomainName>EnabledDomain</DomainName> 
          <DefaultValue xsi:type="xs:short">1</DefaultValue> 
        </SubtypeFieldInfo>
     </FieldInfos>
  </Subtype>
<Subtype xsi:type="esri:Subtype">
    <SubtypeName>Hydrant laterals</SubtypeName> 
    <SubtypeCode>1</SubtypeCode> 
  <FieldInfos xsi:type="esri:ArrayOfSubtypeFieldInfo">
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>H_CONFID</FieldName> 
          <DefaultValue xsi:type="xs:int">0</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>DIAMETER</FieldName> 
          <DomainName>LatDiameter</DomainName> 
          <DefaultValue xsi:type="xs:double">8</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>DEPTH_BURI</FieldName> 
          <DefaultValue xsi:type="xs:double">0</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>RECORDED_L</FieldName> 
          <DefaultValue xsi:type="xs:double">0</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>WNM_TYPE</FieldName> 
          <DefaultValue xsi:type="xs:string">WHYDLIN</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>PWTYPE</FieldName> 
          <DefaultValue xsi:type="xs:string">WHYDLIN</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>MATERIAL</FieldName> 
          <DomainName>Material</DomainName> 
          <DefaultValue xsi:type="xs:string">DI</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>ENABLED</FieldName> 
          <DomainName>EnabledDomain</DomainName> 
          <DefaultValue xsi:type="xs:short">1</DefaultValue> 
        </SubtypeFieldInfo>
     </FieldInfos>
  </Subtype>
<Subtype xsi:type="esri:Subtype">
    <SubtypeName>Fire laterals</SubtypeName> 
    <SubtypeCode>2</SubtypeCode> 
  <FieldInfos xsi:type="esri:ArrayOfSubtypeFieldInfo">
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>H_CONFID</FieldName> 
          <DefaultValue xsi:type="xs:int">0</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>DIAMETER</FieldName> 
          <DomainName>LatDiameter</DomainName> 
          <DefaultValue xsi:type="xs:double">8</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>DEPTH_BURI</FieldName> 
          <DefaultValue xsi:type="xs:double">0</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>RECORDED_L</FieldName> 
          <DefaultValue xsi:type="xs:double">0</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>WNM_TYPE</FieldName> 
          <DefaultValue xsi:type="xs:string">WFIRELIN</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>PWTYPE</FieldName> 
          <DefaultValue xsi:type="xs:string">WFIRELIN</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>MATERIAL</FieldName> 
          <DomainName>Material</DomainName> 
         <DefaultValue xsi:type="xs:string">DI</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>ENABLED</FieldName> 
          <DomainName>EnabledDomain</DomainName> 
          <DefaultValue xsi:type="xs:short">1</DefaultValue> 
        </SubtypeFieldInfo>
     </FieldInfos>
  </Subtype>
<Subtype xsi:type="esri:Subtype">
    <SubtypeName>Service laterals</SubtypeName> 
    <SubtypeCode>3</SubtypeCode> 
  <FieldInfos xsi:type="esri:ArrayOfSubtypeFieldInfo">
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>H_CONFID</FieldName> 
          <DefaultValue xsi:type="xs:int">0</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>DIAMETER</FieldName> 
          <DomainName>LatDiameter</DomainName> 
          <DefaultValue xsi:type="xs:double">8</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>DEPTH_BURI</FieldName> 
          <DefaultValue xsi:type="xs:double">0</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>RECORDED_L</FieldName> 
          <DefaultValue xsi:type="xs:double">0</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>WNM_TYPE</FieldName> 
          <DefaultValue xsi:type="xs:string">WSERVICE</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>PWTYPE</FieldName> 
          <DefaultValue xsi:type="xs:string">WSERVICE</DefaultValue> 
       </SubtypeFieldInfo>
     <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>MATERIAL</FieldName> 
          <DomainName>Material</DomainName> 
          <DefaultValue xsi:type="xs:string">DI</DefaultValue> 
        </SubtypeFieldInfo>
      <SubtypeFieldInfo xsi:type="esri:SubtypeFieldInfo">
          <FieldName>ENABLED</FieldName> 
          <DomainName>EnabledDomain</DomainName> 
          <DefaultValue xsi:type="xs:short">1</DefaultValue> 
        </SubtypeFieldInfo>
     </FieldInfos>
   </Subtype>
 </Subtypes>

Related Topics


8/19/2013