Network datasets in SQL Server

Network datasets are collections of feature classes that possess a connectivity relationship. Network datasets are created using three types of sources—edge feature sources, such as street centerlines; junction feature sources, such as point feature classes containing railroad crossings; and turn feature sources. They are used to model transportation. To use network datasets, you must have the ArcGIS Network Analyst extension installed.

Network datasets in ArcGIS Desktop

In the Catalog tree, feature datasets that contain network datasets in SQL Server look the same until you expand the dataset. Once the dataset is expanded, you see the network dataset, which is represented by the following icon:

Network dataset icon

The name of the network in a geodatabase in SQL Server contains the database name, the name of the network owner, and the name of the network itself.

For example, a network dataset, roads_nd, owned by RJP in the geodatabase sdedb, would be listed in the Catalog tree as sdedb.RJP.roads_nd.

When you create a network dataset, a system junctions feature class is also created. This feature class has the name of the network dataset followed by _Junctions.

Network datasets in a Microsoft SQL Server database

Network datasets are tracked in the GDB_ITEMS table. The GDB_ITEMTYPES table stores a value indicating that the object is a network dataset. The GDB_ITEMRELATIONSHIPS table stores information on how the network and the feature dataset it is in are related.

There are also tables that are created in the schema of the user who owns the network dataset. They are as follows:

The ID in the names of the first six tables is the logicial network ID. The itemID in the last two tables is the ObjectID from the GDB_ITEMS table.

The structures for the tables are as follows:

N_<ID>_DESC

The N_<ID>_Desc table contains items for each junction, edge, and turn element in the network dataset.

Field name

Field type

Description

Null?

OID

integer

The unique identifier of an element in a network

NOT NULL

userclassid

smallint

The identifier of the feature class to which the element belongs

NOT NULL

userid

integer

The ObjectID of the feature

NOT NULL

usersubid

integer

The identifier of an element in a feature; only applicable to complex edge features

NOT NULL

elementtype

smallint

A code indicating the type of network element

NOT NULL

EID

integer

The unique element identifier of the network element; only unique for the type of network element

NOT NULL

N_<ID>_PROPS

The N_<ID>_PROPS table contains a summary description of a network's properties, such as element counts and maximum EID values.

Field name

Field type

Description

Null?

propertyid

integer

The unique identifier of the network property

NOT NULL

propertyname

nvarchar(32)

The name of the property

NOT NULL

propertyvalue

integer

The value of the property

NOT NULL

ND_<ItemID>_DIRTYAREAS

The ND_<ITEMID>_DIRTYAREAS table tracks what spatial features in the network dataset have been edited.

Field name

Field type

Description

Null?

objectid

integer

Unique identifier for the record

NOT NULL

isretired

integer

Indicates whether this feature is still used to track the dirty area of a network dataset

NOT NULL

dirtyarea

integer

geometry

geography

The polygon geometry of the dirty area

ND_<ItemID>_DIRTYOBJECTS

The ND_<ITEMID>_DIRTYOBJECTS table tracks edited relational objects in the network dataset such as turns and historical traffic records.

Field name

Field type

Description

Null?

objectid

integer

Unique identifier for the record

NOT NULL

classid

integer

The objectID of the dirty object item in the GDB_ITEMS table

NOT NULL

OID

integer

The object ID of the dirty object

NOT NULL

updatetype

smallint

The type of edit performed—insert (0), update (1), or delete (2)—that resulted in the dirty object

NOT NULL

All of the remaining network tables contain the same field names and types. Their structure is as follows:

Field name

Field type

Description

Null?

OID

integer

The unique ID of the varbinarymax page in the table

NOT NULL

pagenumber

integer

The number of the varbinarymax page in the table

NOT NULL

pageblob

varbinary(max)

The description for the element the table is describing, such as edge and edge status

tableid

integer

For the N_<ID>_EDGEWEIGHT, N_<ID>_TURNWEIGHT, and N_<ID>_JUNCTIONWEIGHT BLOB tables, the tableID is the weightID. For the N_<ID>_TOPOLOGY BLOB table, the tableID is the position of the original table within the array of topology tables defined in the GeoDatabase\GeoDatabase\Network\Network\TableDefs.h file.

NOT NULL

The following is a diagram of a network dataset in SQL Server:

Network dataset tables in SQL Server

Dashed lines indicate implicit relationships between columns.

There are additional, optional tables you may use as part of your network dataset to model travel times based on historical traffic speeds or denote changes in time zone that could affect network analysis. These are tables that you create prior to creating your network dataset and are stored in your schema (just like the feature class on which a network is built is in the creator's schema). You specify the names of the tables. See the Network Analyst section of the documentation for details on using these historical traffic and time zone tables.

Network datasets in an XML workspace document

The following is an excerpt from an XML document created by exporting from a network dataset. The edge and junction elements' properties are listed below:

<EdgeFeatureSources xsi:type="esri:ArrayOfEdgeFeatureSource">
  <EdgeFeatureSource xsi:type="esri:EdgeFeatureSource">
    <ID>1</ID> 
    <ClassID>99</ClassID> 
    <Name>sdedb.RJP.Road_cl</Name> 
    <ElementType>esriNETEdge</ElementType> 
    <Properties xsi:nil="true" /> 
    <FromElevationFieldName /> 
    <ToElevationFieldName /> 
    <Connectivity xsi:type="esri:PropertySet">
      <PropertyArray xsi:type="esri:ArrayOfPropertySetProperty">
        <PropertySetProperty xsi:type="esri:PropertySetProperty">
          <Key>Version</Key> 
          <Value xsi:type="xs:short">1</Value> 
        </PropertySetProperty>
        <PropertySetProperty xsi:type="esri:PropertySetProperty">
          <Key>UsesSubtypes</Key> 
          <Value xsi:type="xs:short">0</Value> 
        </PropertySetProperty>
        <PropertySetProperty xsi:type="esri:PropertySetProperty">
          <Key>ClassConnectivity</Key> 
          <Value xsi:type="xs:short">1</Value> 
        </PropertySetProperty>
        <PropertySetProperty xsi:type="esri:PropertySetProperty">
          <Key>SubtypeConnCount</Key> 
          <Value xsi:type="xs:int">0</Value> 
        </PropertySetProperty>
        <PropertySetProperty xsi:type="esri:PropertySetProperty">
          <Key>DefaultGroup</Key> 
          <Value xsi:type="xs:int">1</Value> 
        </PropertySetProperty>
        <PropertySetProperty xsi:type="esri:PropertySetProperty">
          <Key>GroupCount</Key> 
          <Value xsi:type="xs:int">0</Value> 
        </PropertySetProperty>
      </PropertyArray>
    </Connectivity>
  </EdgeFeatureSource>
</EdgeFeatureSources>
<JunctionFeatureSources xsi:type="esri:ArrayOfJunctionFeatureSource" /> 
  <SystemJunctionSources xsi:type="esri:ArrayOfSystemJunctionSource">
    <SystemJunctionSource xsi:type="esri:SystemJunctionSource">
      <ID>2</ID> 
      <ClassID>1683</ClassID> 
      <Name>sdedb.RJP.Roads_ND_Junctions</Name> 
      <ElementType>esriNETJunction</ElementType> 
      <Properties xsi:nil="true" /> 
      <ElevationFieldName /> 
    </SystemJunctionSource>
   </SystemJunctionSources>
 <TurnFeatureSources xsi:type="esri:ArrayOfTurnFeatureSource" /> 
   <EvaluatedNetworkAttributes xsi:type="esri:ArrayOfEvaluatedNetworkAttribute">
     <EvaluatedNetworkAttribute xsi:type="esri:EvaluatedNetworkAttribute">
       <ID>1</ID> 
       <Name>speed</Name> 
       <Units>Unknown</Units> 
       <DataType>esriNADTBoolean</DataType> 
       <UsageType>esriNAUTRestriction</UsageType> 
       <UserData xsi:nil="true" /> 
       <UseByDefault>true</UseByDefault> 
       <AttributeParameters xsi:type="esri:ArrayOfNetworkAttributeParameter" /> 
     </EvaluatedNetworkAttribute>
     <EvaluatedNetworkAttribute xsi:type="esri:EvaluatedNetworkAttribute">
       <ID>2</ID> 
       <Name>oneway</Name> 
       <Units>Unknown</Units> 
       <DataType>esriNADTBoolean</DataType> 
       <UsageType>esriNAUTRestriction</UsageType> 
       <UserData xsi:nil="true" /> 
       <UseByDefault>true</UseByDefault> 
       <AttributeParameters xsi:type="esri:ArrayOfNetworkAttributeParameter" /> 
     </EvaluatedNetworkAttribute>
     <EvaluatedNetworkAttribute xsi:type="esri:EvaluatedNetworkAttribute">
       <ID>3</ID> 
       <Name>timeofday</Name> 
       <Units>Unknown</Units> 
       <DataType>esriNADTInteger</DataType> 
       <UsageType>esriNAUTCost</UsageType> 
       <UserData xsi:nil="true" /> 
       <UseByDefault>true</UseByDefault> 
       <AttributeParameters xsi:type="esri:ArrayOfNetworkAttributeParameter" /> 
     </EvaluatedNetworkAttribute>
   </EvaluatedNetworkAttributes>
   <NetworkAssignments xsi:type="esri:ArrayOfNetworkAssignment">
     <NetworkAssignment xsi:type="esri:NetworkAssignment">
       <IsDefault>true</IsDefault> 
       <ID>-1</ID> 
       <NetworkAttributeName>speed</NetworkAttributeName> 
       <NetworkElementType>esriNETJunction</NetworkElementType> 
       <NetworkEvaluatorCLSID>{318C4B91-F5D2-467A-996C-0AB51B0D8FF2}</NetworkEvaluatorCLSID> 
       <NetworkEdgeDirection>esriNEDNone</NetworkEdgeDirection> 
       <NetworkEvaluatorData xsi:type="esri:PropertySet">
         <PropertyArray xsi:type="esri:ArrayOfPropertySetProperty">
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>Version</Key> 
             <Value xsi:type="xs:short">1</Value> 
           </PropertySetProperty>
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>ConstantValue</Key> 
             <Value xsi:type="xs:boolean">false</Value> 
           </PropertySetProperty>
         </PropertyArray>
       </NetworkEvaluatorData>
     </NetworkAssignment>
     <NetworkAssignment xsi:type="esri:NetworkAssignment">
       <IsDefault>true</IsDefault> 
       <ID>-1</ID> 
       <NetworkAttributeName>speed</NetworkAttributeName> 
       <NetworkElementType>esriNETEdge</NetworkElementType> 
       <NetworkEvaluatorCLSID>{318C4B91-F5D2-467A-996C-0AB51B0D8FF2}</NetworkEvaluatorCLSID> 
       <NetworkEdgeDirection>esriNEDNone</NetworkEdgeDirection> 
       <NetworkEvaluatorData xsi:type="esri:PropertySet">
         <PropertyArray xsi:type="esri:ArrayOfPropertySetProperty">
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>Version</Key> 
             <Value xsi:type="xs:short">1</Value> 
           </PropertySetProperty>
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>ConstantValue</Key> 
             <Value xsi:type="xs:boolean">false</Value> 
           </PropertySetProperty>
         </PropertyArray>
       </NetworkEvaluatorData>
     </NetworkAssignment>
     <NetworkAssignment xsi:type="esri:NetworkAssignment">
       <IsDefault>true</IsDefault> 
       <ID>-1</ID> 
       <NetworkAttributeName>speed</NetworkAttributeName> 
       <NetworkElementType>esriNETTurn</NetworkElementType> 
       <NetworkEvaluatorCLSID>{318C4B91-F5D2-467A-996C-0AB51B0D8FF2}</NetworkEvaluatorCLSID> 
       <NetworkEdgeDirection>esriNEDNone</NetworkEdgeDirection> 
       <NetworkEvaluatorData xsi:type="esri:PropertySet">
         <PropertyArray xsi:type="esri:ArrayOfPropertySetProperty">
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>Version</Key> 
             <Value xsi:type="xs:short">1</Value> 
           </PropertySetProperty>
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>ConstantValue</Key> 
             <Value xsi:type="xs:boolean">false</Value> 
           </PropertySetProperty>
         </PropertyArray>
       </NetworkEvaluatorData>
     </NetworkAssignment>
     <NetworkAssignment xsi:type="esri:NetworkAssignment">
       <IsDefault>true</IsDefault> 
       <ID>-1</ID> 
       <NetworkAttributeName>oneway</NetworkAttributeName> 
       <NetworkElementType>esriNETJunction</NetworkElementType> 
       <NetworkEvaluatorCLSID>{318C4B91-F5D2-467A-996C-0AB51B0D8FF2}</NetworkEvaluatorCLSID> 
       <NetworkEdgeDirection>esriNEDNone</NetworkEdgeDirection> 
       <NetworkEvaluatorData xsi:type="esri:PropertySet">
         <PropertyArray xsi:type="esri:ArrayOfPropertySetProperty">
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>Version</Key> 
             <Value xsi:type="xs:short">1</Value> 
           </PropertySetProperty>
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>ConstantValue</Key> 
             <Value xsi:type="xs:boolean">false</Value> 
           </PropertySetProperty>
         </PropertyArray>
       </NetworkEvaluatorData>
     </NetworkAssignment>
     <NetworkAssignment xsi:type="esri:NetworkAssignment">
       <IsDefault>true</IsDefault> 
       <ID>-1</ID> 
       <NetworkAttributeName>oneway</NetworkAttributeName> 
       <NetworkElementType>esriNETEdge</NetworkElementType> 
       <NetworkEvaluatorCLSID>{318C4B91-F5D2-467A-996C-0AB51B0D8FF2}</NetworkEvaluatorCLSID> 
       <NetworkEdgeDirection>esriNEDNone</NetworkEdgeDirection> 
       <NetworkEvaluatorData xsi:type="esri:PropertySet">
         <PropertyArray xsi:type="esri:ArrayOfPropertySetProperty">
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>Version</Key> 
             <Value xsi:type="xs:short">1</Value> 
           </PropertySetProperty>
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>ConstantValue</Key> 
             <Value xsi:type="xs:boolean">false</Value> 
           </PropertySetProperty>
         </PropertyArray>
       </NetworkEvaluatorData>
     </NetworkAssignment>
     <NetworkAssignment xsi:type="esri:NetworkAssignment">
       <IsDefault>true</IsDefault> 
       <ID>-1</ID> 
       <NetworkAttributeName>oneway</NetworkAttributeName> 
       <NetworkElementType>esriNETTurn</NetworkElementType> 
       <NetworkEvaluatorCLSID>{318C4B91-F5D2-467A-996C-0AB51B0D8FF2}</NetworkEvaluatorCLSID> 
       <NetworkEdgeDirection>esriNEDNone</NetworkEdgeDirection> 
       <NetworkEvaluatorData xsi:type="esri:PropertySet">
         <PropertyArray xsi:type="esri:ArrayOfPropertySetProperty">
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>Version</Key> 
             <Value xsi:type="xs:short">1</Value> 
           </PropertySetProperty>
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>ConstantValue</Key> 
             <Value xsi:type="xs:boolean">false</Value> 
           </PropertySetProperty>
         </PropertyArray>
       </NetworkEvaluatorData>
     </NetworkAssignment>
     <NetworkAssignment xsi:type="esri:NetworkAssignment">
       <IsDefault>true</IsDefault> 
       <ID>-1</ID> 
       <NetworkAttributeName>timeofday</NetworkAttributeName> 
       <NetworkElementType>esriNETJunction</NetworkElementType> 
       <NetworkEvaluatorCLSID>{318C4B91-F5D2-467A-996C-0AB51B0D8FF2}</NetworkEvaluatorCLSID> 
       <NetworkEdgeDirection>esriNEDNone</NetworkEdgeDirection> 
       <NetworkEvaluatorData xsi:type="esri:PropertySet">
         <PropertyArray xsi:type="esri:ArrayOfPropertySetProperty">
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>Version</Key> 
             <Value xsi:type="xs:short">1</Value> 
           </PropertySetProperty>
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>ConstantValue</Key> 
             <Value xsi:type="xs:int">0</Value> 
           </PropertySetProperty>
         </PropertyArray>
       </NetworkEvaluatorData>
     </NetworkAssignment>
     <NetworkAssignment xsi:type="esri:NetworkAssignment">
       <IsDefault>true</IsDefault> 
       <ID>-1</ID> 
       <NetworkAttributeName>timeofday</NetworkAttributeName> 
       <NetworkElementType>esriNETEdge</NetworkElementType> 
       <NetworkEvaluatorCLSID>{318C4B91-F5D2-467A-996C-0AB51B0D8FF2}</NetworkEvaluatorCLSID> 
       <NetworkEdgeDirection>esriNEDNone</NetworkEdgeDirection> 
       <NetworkEvaluatorData xsi:type="esri:PropertySet">
         <PropertyArray xsi:type="esri:ArrayOfPropertySetProperty">
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>Version</Key> 
             <Value xsi:type="xs:short">1</Value> 
           </PropertySetProperty>
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>ConstantValue</Key> 
             <Value xsi:type="xs:int">0</Value> 
           </PropertySetProperty>
         </PropertyArray>
       </NetworkEvaluatorData>
     </NetworkAssignment>
     <NetworkAssignment xsi:type="esri:NetworkAssignment">
       <IsDefault>true</IsDefault> 
       <ID>-1</ID> 
       <NetworkAttributeName>timeofday</NetworkAttributeName> 
       <NetworkElementType>esriNETTurn</NetworkElementType> 
       <NetworkEvaluatorCLSID>{318C4B91-F5D2-467A-996C-0AB51B0D8FF2}</NetworkEvaluatorCLSID> 
       <NetworkEdgeDirection>esriNEDNone</NetworkEdgeDirection> 
       <NetworkEvaluatorData xsi:type="esri:PropertySet">
         <PropertyArray xsi:type="esri:ArrayOfPropertySetProperty">
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>Version</Key> 
             <Value xsi:type="xs:short">1</Value> 
           </PropertySetProperty>
           <PropertySetProperty xsi:type="esri:PropertySetProperty">
             <Key>ConstantValue</Key> 
             <Value xsi:type="xs:int">0</Value> 
           </PropertySetProperty>
         </PropertyArray>
       </NetworkEvaluatorData>
     </NetworkAssignment>
   </NetworkAssignments>
 <ConfigurationKeyword>NETWORK_DEFAULTS</ConfigurationKeyword>

Related Topics


8/19/2013