Load Territory Records (Territory Design)

Доступно с лицензией Business Analyst.

Сводка

Adds records (features) or updates existing records for the specified level.

Использование

  • Specifies an existing territory solution.

  • Specifies the level where records are to be added.

  • A point layer will add records to the Territories Centers layer.

  • A polygon layer will add records to the Territories Boundary layer.

  • The tool requires a feature layer or table for input.

Синтаксис

arcpy.td.LoadTerritoryRecords(in_territory_solution, level, in_data, {id_field}, {name_field}, {field_map}, {append_data})
ParameterОбъяснениеТип данных
in_territory_solution

The input territory solution.

Group Layer; Feature Dataset; String
level

The level where the data will be loaded.

String
in_data

The layer or records to be loaded.

Table View
id_field
(Дополнительный)

The field containing ID values to be loaded into the level.

Field
name_field
(Дополнительный)

The field containing name values to be loaded into the level.

Field
field_map
[[attribute, field],...]
(Дополнительный)

Sets the values for the territory properties.

  • PARENT_TERRITORY_ID—The ID of the parent territory.
  • LOCKED_STATE—Territory can't be modified.
  • CENTER_LOCKED—Center points can't be modified and will remain in their fixed locations.

Value Table
append_data
(Дополнительный)

Specifies where to append or replace the records being loaded.

  • APPENDAppends records to the specified level.
  • REPLACEReplaces records to the specified level. This is the default.
Boolean

Производные выходные данные

NameОбъяснениеТип данных
out_territory_solution

The updated territory solution.

Group Layer

Пример кода

LoadTerritoryRecords example (Python window)

The following Python window script demonstrates how to use the LoadTerritoryRecords tool.

import arcpy
arcpy.td.LoadTerritoryRecords("Territory Solution", "Level[1]", r"C:\Temp \sampledata.gdb\StoreLocations", "ID", "Name", None, "REPLACE")

Информация о лицензиях

  • Basic: Требуется Business Analyst
  • Standard: Требуется Business Analyst
  • Advanced: Требуется Business Analyst

Связанные разделы