Print this page

How do I reset/restart an auto number field?

Knowledge Article Number 000005195
Description

How do I reset/restart an auto number field?

Resolution

From time to time users may want to reset or restart an auto number field. For example, you may have a 5 digit auto-number where the first two digits represent the year and the last three digits would be a rolling count of records for a given year. For 2006, the first record would be 06001 and for 2007 the first record would be number 07001.

This can be accomplished with the following steps:

For Custom Auto-Number Fields

1. Click on Your Name | Setup | Build | Customize | Object Name | Fields
2. Click Edit next to the Auto-Number field you want to modify
3. Click "Change Field Type" and select the Data Type as 'Text' and click 'Next'.

NOTE: This does not work for Standard Auto-Number fields like Case Number, Solution Number etc. For Standard Auto Number fields, the steps are given at the bottom.


4. Click 'Save' on the next Screen (Step 2) unless you want to modify the Field Level Security for profiles, which is there on the next screen (Step 3). Now you the data stored on Auto Number field is converted into Text values.
5. Repeat Step 1 to 3. However, in step 3 change the Data Type back to Auto Number.

NOTE: This step would allow you to set the starting auto-number.

6. Now you will receive a pop-up with the following message: "The new Display Format will only be applied to new records. Existing records will remain unchanged."
7. Click OK

For Standard Auto-Number Fields

Follow these steps to change the display format of the Auto-Number field and define a starting number

1. Click on Your Name | Setup | Build | Customize | Object Name | Fields
2. Click Edit next to the Auto-Number field you want to modify
3. Change the Display Format and Next Number you want to be displayed for your records. And click Save.
4. You will receive a pop-up with the following message: “This may result in duplicate number. Are you sure?”
5. Click Ok

NOTE: This does not work for objects installed by managed released packages, as components below are locked:

- "data type" on custom field
- "record name data type" on custom object
- "record name display format" on custom object


If you want to restart auto number fields on objects from a managed released package, you can uninstall the package and reinstall it.





promote demote