ListIndexes
摘要
Lists the indexes in a feature class, shapefile, or table in a specified dataset. The Python List returned can be limited with search criteria for index name and will contain index objects.
语法
ListIndexes (dataset, {wild_card})
| 参数 | 说明 | 数据类型 |
dataset |
The specified feature class or table whose indexes will be returned. | String |
wild_card |
通配符可限制返回的结果。如果未指定任何通配符,则会返回所有值。 | String |
| 数据类型 | 说明 |
| Index |
A Python List containing Index objects is returned. |
代码示例
ListIndexes example
List index properties.
import arcpy
fc = "C:/Data/roads.shp"
# Get list of indexes for roads.shp and print properties to interactive window
#
indexes = arcpy.ListIndexes(fc)
for index in indexes:
print "%-11s : %s" %("Name",index.name)
print "%-11s : %s" %("IsAscending",index.isAscending)
print "%-11s : %s" %("IsUnique",index.isUnique)
相关主题
7/10/2012