Is there a way to auto generate ID numbers based on a subtype field?

222
3
09-20-2018 01:29 PM
Highlighted
New Contributor

I'm using the Attribute Assistant add on to try to achieve this task. Is there an expression that I could write in the DynamicValue table so that the tool looks at the subtype field of a feature class and then determines which Sequence that it needs to use?

For example, I'm working with a dummy valve feature class where there are two subtypes : 3 and 6.

The largest Subtype 3 valve ID number is 0107910, and the largest Subtype 6 valve ID is 1702300. How can I get the tool to update these two ID numbers independently but within the same feature class?

Reply
0 Kudos
3 Replies
Highlighted
New Contributor III

Austin, are you looking to update the ID so that when, for example, Subtype 3 gets an sequence and Subtype 6 gets its own sequence in the same features ID attribute?

Reply
0 Kudos
Highlighted
MVP Esteemed Contributor

I think if you create individual rows in yourGenerate ID table for each, you should be able to. ( Configure GenerateID table - Attribute Assistant | ArcGIS Solutions )  However, your use of an ID with a leading zero ( 0107910) may be problematic for you.

Reply
0 Kudos
Highlighted
Esri Contributor

Hi Austin, We just ran across a similar thing on a support case and i wanted to share this as it might help. 

Attached is working sample and proof of concept to assist in your own workflows.

http://www.arcgis.com/home/item.html?id=ac2fd27fadeb4bb0849fce47930093b0 

We know a Generate ID method can only have one count per field, Given this, this example uses a Sub-type field, and 3 Separate Id fields each with their own Generate ID Methods. The Sybtype filed is responsible for setting the attribute (1,2,3) in The Sybtype. A series of Field Trigger reads the Subtype value and adds a place holder value in the opposing ID fields. The Generate ID running on each ID field will only activate on the Null record and thus count each subtype independently. 

Supporting Documentation:
https://solutions.arcgis.com/shared/help/attribute-assistant/documentation/methods-all-methods/#fiel...
https://solutions.arcgis.com/shared/help/attribute-assistant/documentation/methods-all-methods/#gene...
https://desktop.arcgis.com/en/arcmap/10.3/manage-data/subtypes/creating-subtypes.htm

Reply
0 Kudos