TableToArrowTable

サマリー

Converts a table or feature class to an Apache Arrow table.

説明

Apache Arrow is a standard cross-platform in-memory representation of columnar data. An Arrow table is a two-dimensional tabular representation in which columns are Arrow chunked arrays. The data types for the columns are determined by the field types of the input table or feature class, with support for types unique to ArcGIS Pro provided by Arrow extension types.

Geoprocessing tools that accept a table or feature class as input (and do not modify the input) will accept a PyArrow table as input. While a geoprocessing tool will accept an Arrow table as input, a tool will not output an Arrow table.

Learn more about Apache Arrow in ArcGIS

構文

TableToArrowTable (in_table)
パラメーター説明データ タイプ
in_table

フィーチャクラス、レイヤー、テーブル、またはテーブル ビュー。

String
戻り値
データ タイプ説明
PyArrowTable

The output pyarrow.Table. See the pyarrow.Table object API.

コードのサンプル

TableToArrowTable example

Convert a feature class to an Arrow table and count the number of counties in the dataset.

import arcpy

input = r'C:\data\usa.gdb\USA\counties'
arrow_table = arcpy.da.TableToArrowTable(input)

# Get the number of counties in the dataset
count = arcpy.management.GetCount(arrow_table)
print("Number of US Counties:", count)

関連トピック


このトピックの内容