ArcGIS for Desktop

  • Documentation
  • Pricing
  • Support

  • My Profile
  • Help
  • Sign Out
ArcGIS for Desktop

ArcGIS Online

The mapping platform for your organization

ArcGIS for Desktop

A complete professional GIS

ArcGIS for Server

GIS in your enterprise

ArcGIS for Developers

Tools to build location-aware apps

ArcGIS Solutions

Free template maps and apps for your industry

ArcGIS Marketplace

Get apps and data for your organization

  • Documentation
  • Pricing
  • Support
Esri
  • Sign In
user
  • My Profile
  • Sign Out

Help

  • Home
  • Get Started
  • Map
  • Analyze
  • Manage Data
  • Tools
  • More...

Update by Geometry

Available with Network Analyst license.

  • Summary
  • Usage
  • Syntax
  • Code Sample
  • Environments
  • Licensing Information

Summary

Updates all the edge references in the turn feature class using the geometry of the turn features. This tool is useful when the IDs listed for the turn can no longer find the edges participating in the turn due to edits to the underlying edges.

Usage

  • The tool updates the Edge#FID field values on the turn feature class based on the coincidence between the turn features and the edge features from the network sources.

  • Errors encountered when updating the turn features are reported in an error file written to the directory defined by the TEMP system variable. The full path name to the error file is reported as a warning message.

Syntax

UpdateByGeometry_na (in_turn_features)
ParameterExplanationData Type
in_turn_features

The turn feature class to be updated.

Feature Layer

Code Sample

UpdateByGeometry example 1 (Python window)

Execute the tool using all parameters.

turns = "C:/Data/SanFrancisco.gdb/Transportation/RestrictedTurns"
arcpy.na.UpdateByGeometry(turns)
UpdateByGeometry example 2 (stand-alone Python script)

The following Python script demonstrates how to use the UpdateByGeometry tool in a stand-alone script.

# Name: UpdateByGeometry_ex02.py
# Description: Update edge references in the turn feature class using the
#              geometry of turn features and re-build the network dataset.
# Requirements: Network Analyst Extension 

#Import system modules
import arcpy
from arcpy import env

#Check out the Network Analyst extension license
arcpy.CheckOutExtension("Network")

#Set environment settings
env.workspace = "C:/Data/SanFrancisco.gdb"

#Set local variables
turn_features = "RestrictedTurns"
network = "Transportation/Streets_ND"

#Update the edge references in turn features using the geometry
arcpy.na.UpdateByGeometry(turn_features)

#Since we have modified the edge references for turn sources, we should rebuild 
#the network dataset so that the turn features are correctly interpreted by the 
#network dataset
arcpy.na.BuildNetwork(network)

print("Script completed successfully.")

Environments

  • Current Workspace

Licensing Information

  • ArcGIS for Desktop Basic: Yes
  • ArcGIS for Desktop Standard: Yes
  • ArcGIS for Desktop Advanced: Yes

Related Topics

  • Other edits affecting turns
  • An overview of the Turn Feature Class toolset
Feedback on this topic?

ArcGIS for Desktop

  • Home
  • Documentation
  • Pricing
  • Support

ArcGIS Platform

  • ArcGIS Online
  • ArcGIS for Desktop
  • ArcGIS for Server
  • ArcGIS for Developers
  • ArcGIS Solutions
  • ArcGIS Marketplace

About Esri

  • About Us
  • Careers
  • Insiders Blog
  • User Conference
  • Developer Summit
Esri
© Copyright 2016 Environmental Systems Research Institute, Inc. | Privacy | Legal