Import Territory Solution (Territory Design Tools)
汇总
Creates a new territory solution and imports the territories hierarchy from a table or a layer.
用法
参数
|
标注
|
说明
|
数据类型
|
|
Input Data
|
The layer or records to be imported.
|
Table View
|
|
Territory Solution Name
|
The name of the territory solution to be created.
|
String
|
|
Level Settings
|
The level settings for importing the territories hierarchy.
值表列:
Level Name—The name of the level (required).
Default Territory Name—The prefix for the new territories that will, subsequently, be created at the level (optional).
ID Field—The field that contains IDs (unique IDs) for territories (required).
Name Field—The field that contains names for territories (optional).
Parent ID Field—The field that contains IDs of parent territories (optional).
Primary Feature Class—Specifies the class level that will be used for storing level attributes (optional).
Territory Boundaries—Level attributes will be stored using the boundaries of the territory solution.
Territory Centers—Level attributes will be stored using the boundary centers of the territory solution.
Base Boundaries—Level attributes will be stored using the boundaries of the base layer.
Base Centers—Level attributes will be stored using the boundary centers of the base layer.
|
Value Table
|
派生输出
|
标注
|
说明
|
数据类型
|
|
Output Territory Solution
|
The updated territory solution.
|
Group Layer
|
arcpy.td.ImportTerritorySolution(in_data, solution_name, level_settings)
|
名称
|
说明
|
数据类型
|
|
in_data
|
The layer or records to be imported.
|
Table View
|
|
solution_name
|
The name of the territory solution to be created.
|
String
|
|
level_settings
[[level_name, territory_name_template, id_field, name_field, parent_id_field, primary_feature_class],...]
|
The level settings for importing the territories hierarchy.
值表列:
Level Name—The name of the level (required).
Default Territory Name—The prefix for the new territories that will, subsequently, be created at the level (optional).
ID Field—The field that contains IDs (unique IDs) for territories (required).
Name Field—The field that contains names for territories (optional).
Parent ID Field—The field that contains IDs of parent territories (optional).
Primary Feature Class—Specifies the class level that will be used for storing level attributes (optional).
TERRITORY_BOUNDARIES—Level attributes will be stored using the boundaries of the territory solution.
TERRITORY_CENTERS—Level attributes will be stored using the boundary centers of the territory solution.
BASE_BOUNDARIES—Level attributes will be stored using the boundaries of the base layer.
BASE_CENTERS—Level attributes will be stored using the boundary centers of the base layer.
|
Value Table
|
派生输出
|
名称
|
说明
|
数据类型
|
|
out_territory_solution
|
The updated territory solution.
|
Group Layer
|
代码示例
ImportTerritorySolution example (Python window)
The following Python window script demonstrates how to use the ImportTerritorySolution tool.
import arcpy
arcpy.td.ImportTerritorySolution("zips", "Territory Solution", "Base BaseName ID NAME TerritoryID BASE_BOUNDARIES;Territories Territory TerritoryID # # TERRITORY_BOUNDARIES")
环境
Current Workspace
许可信息
- 基本: Requires Business Analyst
- 标准: Requires Business Analyst
- 高级: Requires Business Analyst