Auto-number Field
The Auto-number field type is an automatically generated sequential number or code that uses a display format you define. When you define a start number using a specific display format, the start number is used to initialize the auto-number sequence.
The following properties can be defined while creating a Auto-number field:
-
Field Properties
-
Field Label — (mandatory) is displayed on the left from the field on view, edit, and new record pages.
-
View Header — (optional) is used in headers of views and reports. If not specified, the Field Label is used.
-
View Width — (optional) is used to set width (in pixels or %) of columns in views and reports. If not specified, the browser calculates the width of columns automatically.
-
Default Size — The default size of the input field shown in forms (you can override this default as a page-level property using the page editor).
-
Display Format — (mandatory) This setting is defined by a template. Syntax and examples are presented inline while creating the field.
-
Starting Number — (mandatory) This is required for the sequence number portion.
-
Assign values for all existing object records now — Enable to assign this field to all existing Object records once it is created or updated.
An Auto-number format may include year, month and day. When you create an auto-number field, you must specify:
-
-
Advanced Field Properties — For more information, see Advanced field properties.
-
Integration Name — The integration name is used to reference this field via merge fields or with Platform APIs.
-
Field-Level Help — The Field-Level Help box allows you to define help text for the field that will appear in a popup when the user clicks the help icon next to the field.
The current number indicates a start number that is currently in use to initialize the auto-number sequence. Editing the current number is a separate action. When you update or edit a Current Number:
- Preferably, provide a value that is greater than the existing current number.
- If you choose to specify a lower current number value, check for any existing records for the selected object, and if available, delete all those records from the object and the Recycle Bin.
- Auto-Number fields are read-only and display the text "Auto-generated" when creating a new record. However, you can edit the value of this field on its edit page.
- New number for Auto-Number field is assigned when user saves a new record.
- An auto-number sequence is updated only for a valid format.
- By default, Auto-number fields do not allow duplicate values.
Tip: Auto-Number fields are often used in the Object definition name templates.
Existing Platform users may see Auto-number Functional Changes for more information.