I have over a hundred FCs, each with 10 or 20 attributes to add or change the aliases for, two or more times a year. Needless to say, this is not something I'm going to grunt my way through. How can I automate this process?
Python solution preferred but will use anything that works.
I have access to Arcgis 9.3.1 and 10 (ArcInfo license level).
Answer
As of version 10.1 AlterAliasName() can be used to re-alias tables:
table = r"C:\path\to\connection.sde\OWNER.TABLE"
arcpy.AlterAliasName(table, "table_alias")
As of version 10.3 Alter Field can be used to re-alias fields:
table = r"C:\path\to\connection.sde\OWNER.TABLE"
arcpy.AlterField_management(table, "FIELD_NAME", new_field_alias="field_alias")
No comments:
Post a Comment