Update Property Count (Topographic Production)

Сводка

Increases the value in an extended property by the update value each time the tool is executed so that metrics are recorded.

Прежние версии:

This tool has been replaced by the Update Extended Property tool. and will be deprecated in the next release.

Внимание:

This tool is designed to be run as a step in a Workflow Manager (Classic) workflow. Running this tool outside of Workflow Manager (Classic) does not honor all Workflow Manager (Classic) constraints such as job assignment, dependencies, or holds and may cause a job to enter an unusable state.

Внимание:

This tool is intended for use with the Topographic Mapping production workflows and will not support an improperly configured Workflow Manager (Classic) repository. Sample workflows and instructions for configuring Topographic Mapping production workflows are available as part of the product file installer.

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

  • This tool updates the selected extended property in the identified properties table for the selected job.

  • This tool is intended to support the tracking of various job metrics that are derived from the execution of workflow steps. One such metric is tracking the number of times a job goes back for rework.

  • Populate the Properties Table Name parameter with the name of the table only. You don't need to populate the full database path to the table or the qualified name of the table.

  • The table designated in the Properties Table Name parameter must be registered as an extended property table in Workflow Manager (Classic).

  • The value (field) of the Property Field parameter must be an Integer field.

Синтаксис

UpdatePropertyCount(job_id, properties_table_name, property_field, update_value, {database_path})
ParameterОбъяснениеТип данных
job_id

The ID of the Workflow Manager (Classic) job that will be updated.

Long
properties_table_name

The name of the extended properties table that will be updated.

String
property_field

The property to be updated in the selected extended properties table.

String
update_value

The value by which the selected extended property will be increased.

Long
database_path
(Дополнительный)

The Workflow Manager (Classic) database connection file (.jtc) that contains the job information. If no connection file is specified, the current default Workflow Manager (Classic) database will be used.

File

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

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

The ID of the updated Workflow Manager (Classic) job.

Long

Пример кода

UpdatePropertyCount example (stand-alone script)

This sample script uses the UpdatePropertyCount tool to increase the rework_count field in the TOPO_PRODUCTION_PROPERTIES table by 1.

# Name: UpdatePropertyCount_sample.py
# Description: Sample script for running the Update Property Count tool, and increasing the rework_count field in the
# TOPO_PRODUCTION_PROPERTIES table by 1

# Import System Modules
import arcpy

# Check Out Extensions
arcpy.CheckOutExtension('Foundation')
arcpy.CheckOutExtension('JTX')

# Setting the environment
arcpy.env.overwriteOutput = True

# Setting Local Variables
job_id = 15
property_table = 'TOPO_PRODUCTION_PROPERTIES'
property_field = 'rework_count'
update_value = 1
input_database_connection = r'C:\Data\Workflows\Testing.jtc'

# Calling the Update Property Count tool to increase the value in the rework_count field by 1
arcpy.topographic.UpdatePropertyCount(job_id, property_table, property_field, input_database_connection)

# Getting all messages, warnings, and errors from the tool run and printing the results back to the user
messages = arcpy.GetMessages(0)
warnings = arcpy.GetMessages(1)
errors = arcpy.GetMessages(2)
arcpy.AddMessage('Tool Messages: {}\nTool Warnings: {}\nTool Errors{}\n'.format(messages, warnings, errors))

# Check In Extensions
arcpy.CheckInExtension('Foundation')
arcpy.CheckInExtension('JTX')

Environments

Этот инструмент не использует параметры среды геообработки

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

  • Basic: Нет
  • Standard: Требуется Production Mapping and Workflow Manager
  • Advanced: Требуется Production Mapping and Workflow Manager

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