Import Territories From Database (Territory Design)

许可等级:BasicStandardAdvanced

摘要

Imports an entire territory hierarchy from a territories database.

用法

语法

ImportTerritoriesFromDatabase_TD_td (in_territory_solution_layer, in_database, in_fields_map, {in_al_join_field}, {in_table_join_field})
参数说明数据类型
in_territory_solution_layer

The Territory Solution layer to where to import territories.

GP TD Layer
in_database

The Table with the territories hierarchy data.

Table
in_fields_map
[in_fields_map,...]

The Fields for importing territories hierarchy from database and level names.

Fields Map
in_al_join_field
(可选)

The Field in the Alignment Layer with which to join an imported table.

Field
in_table_join_field
(可选)

The Field in an imported table with which to join the Alignment Layer.

Field

代码实例

ImportTerritoriesFromDatabase example (Python window)

The following Python window script demonstrates how to use the tool in immediate mode.

import arcgisscripting
gp = arcgisscripting.create()
gp.ImportTerritoriesFromDatabase_TD("new layer", "C:/Data/TerritoryHierarchy.dbf", "Territorie Territo_ID Territories;Regions Regions_ID Regions", "ID", "ID")
ImportTerritoriesFromDatabase example 2 (stand-alone script)

The following stand-alone script demonstrates how to use the tool.

# Import system modules
import arcgisscripting
gp = arcgisscripting.create()

# Set local variables
solution = "new layer"
database = "C:/Data/TerritoryHierarchy.dbf"
fieldsMap = "Territorie Territo_ID Territories;Regions Regions_ID Regions"
alJoinField = "ID"
dbJoinField = "ID"

# Execute tool
gp.ImportTerritoriesFromDatabase_TD(solution, database, fieldsMap, alJoinField, dbJoinField)

环境

此工具不使用任何地理处理环境

相关主题

许可信息

ArcGIS for Desktop Basic: 需要 Business Analyst
ArcGIS for Desktop Standard: 需要 Business Analyst
ArcGIS for Desktop Advanced: 需要 Business Analyst
4/27/2014