ID で顧客を割り当て(Assign Customers By ID) (Business Analyst)

ライセンス レベル:BasicStandardAdvanced

サマリ

顧客テーブルの既存の店舗 ID フィールドに基づいて顧客を店舗に割り当てます。

使用法

構文

AssignCustomersByID_ba (CustomerLayer, LinkField, {CreateNewFeatureClass}, {OutputFeatureClass})
パラメータ説明データ タイプ
CustomerLayer

各店舗への顧客の割り当てに使用される顧客レイヤ。

Feature Layer
LinkField

顧客の割り当てに使用する店舗 ID フィールド。

Field
CreateNewFeatureClass
(オプション)

既存のレイヤに基づく新規フィーチャクラスを生成するか、既存のレイヤを使用します。

  • TRUE新しいフィーチャクラスを作成します。
  • FALSE新しいフィーチャクラスを作成しません。元のレイヤが使用されます。
Boolean
OutputFeatureClass
(オプション)

顧客フィーチャが含まれるフィーチャクラス。

Feature Class

コードのサンプル

AssignCustomersByID(ID で顧客を割り当て)の例(スタンドアロン スクリプト)
# Name: AssignCustomersByID.py
# Description: Assigns customers in the San Francisco area to their designated store by a corresponding ID field in both layers.
# Author: Esri

# Import system modules
import arcview
import arcpy

arcpy.ImportToolbox("C:\Program Files (x86)\ArcGIS\Desktop10.2\Business Analyst\ArcToolbox\Toolboxes\Business Analyst Tools.tbx")
 
try:
# Acquire extension license 
  arcpy.CheckOutExtension("Business") 
 	
# Defines the parameters for the Assign Customers by ID tool
  CustPath = "C:/temp/sf_cust.shp"
  StoreId = "STORE_ID"
 
# Assign Customers by ID 
  arcpy.AssignCustomersByID_ba(CustPath, StoreId, "false")
 
# Release extension license 
  arcpy.CheckInExtension("Business") 
 
except:
  print arcpy.GetMessages(2)

環境

このツールはジオプロセシング環境を使用していません

関連トピック

ライセンス情報

ArcGIS for Desktop Basic: 次のものが必要 Business Analyst
ArcGIS for Desktop Standard: 次のものが必要 Business Analyst
ArcGIS for Desktop Advanced: 次のものが必要 Business Analyst
5/20/2014