Auto Populating a Unique ID Field

Jump to solution
10-20-2015 09:57 AM
New Contributor III

I'm currently working off a versioned SDE database and I'm trying to symbolize a unique id for point and line features.  Usually I just symbolize off the OID but this number cannot change.  Sometimes the point or line may get deleted and recreated.  I have no issue with pulling the unique Id out and reentering it but as most of you know this is not possible to do with an OID. 

So, is it possible to have a unique id field that automatically inputs a value one higher than the previous version?  If that is not possible is there a way to automatically copy the OID into another field so it's editable?



0 Kudos
1 Solution

Accepted Solutions
MVP Regular Contributor
3 Replies
Regular Contributor III

I haven't seen an automated way of creating a incremented unique id field. You could create a field and use the field calculator to populate using the object ID field see below.

0 Kudos
MVP Regular Contributor

You could use the attribute assistant: Configure Attribute Assistant - Special Event Planning | ArcGIS for State Government

look under Generate ID Table

Occasional Contributor III

For non-ArcObjects programmers or users that wants an out-of-the-box option you'll want to use Tim's solution. The attribute assistant provides a mechanism that does this. Otherwise you could implement a feature class extension in ArcObjects to handle this.