Select to view content in your preferred language

Auto Populating a Unique ID Field

2819
3
Jump to solution
10-20-2015 09:57 AM
AlexanderPugliese
Emerging Contributor

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?

Thanks!

~alex

0 Kudos
1 Solution

Accepted Solutions
TimWitt2
MVP Alum
3 Replies
WesMiller
Deactivated User

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
TimWitt2
MVP Alum

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

look under Generate ID Table

FreddieGibson
Honored Contributor

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.