Just as the title asks, how do I set the startpoint for an autonumber after field creation? The field is an external Id and to avoid conflict with the external system, I need to move the id up a few numbers.

  • even if you set an arbitrarily high number, is it not conceivable that the numbers might overlap at some point? Or is the creation of the object solely driven by the existence of the external record?
    – ebt
    Commented Aug 20, 2012 at 15:47
  • @ebt: The data in the external system is setup like so: [1...OPEN...10][11...FILLED...20][21...OPEN] where there is a chunk of occupied Ids. I can't say why the data got into this state. Commented Aug 20, 2012 at 15:55

2 Answers 2


You can convert the field type to text, then convert it back to auto number. When you convert it back, you'll have the option to set the starting number again. I might do this after hours if there is a danger of a record being created while you're doing the field conversion.


  • Note that this isn't possible for managed auto-number fields, where there's no way currently to force a specific value, since they can't be converted to text. Commented Oct 16, 2013 at 20:17

Changing the field type is a good idea. Alternately, if you're only going to move the auto-number up by a few numbers or even a few tens of numbers, you could insert some records and delete them. Crude but effective.

  • 1
    This is the only time I don't mind that tests increment auto-number fields. If you can't or don't want to change the field type, you can run a test method that just inserts the number of records you need the auto-number moved up by. Then you don't actually have to create and delete records.
    – Rob Scott
    Commented Aug 20, 2012 at 21:07
  • I was tempted to do this but there is a complex object hierarchy that would also have to be created. Commented Aug 21, 2012 at 13:58

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .