You are here:
Custom Field Attributes
A custom field has different attributes depending on its field type.
| Field | Description |
|---|---|
| # Visible Lines | For Long Text Area fields, set the number of lines to be shown on Edit pages. You can show from 2 through 50 lines (the default is 6 lines). If the text doesn't fit in the specified number of visible lines, scroll bars appear. Long Text Area fields are fully shown on detail pages and printable views. This attribute's value isn't respected for Long Text Area and Rich Text Area fields in Lightning Experience. |
| Calculation Options | Determines how a roll-up summary field is recalculated after its properties change. Select Automatic calculation to recalculate a field the next time it’s displayed. Select Force a mass recalculation of this field as a safety net option to force recalculation of the roll-up summary field values. |
| Child Relationship Name | The name used in API SOQL relationship queries. |
| Data Type | The data type of a field determines what type of information is in the field. For example, a field with the Number data type contains a positive or negative integer. For more information on data types, see Custom Field Types. |
| Decimal Places | For currency, geolocation, number, and percent fields, this field represents the number of digits you can enter to the right of a decimal point. The system rounds the decimal numbers that you enter, if necessary. For example, if you enter 4.986 in a field with Decimal Places set to 2, the number rounds to 4.99. |
| Default Value | The value to apply when a user creates a record. For custom checkbox fields, select Checked or Unchecked as the default value to indicate the default when creating records. Don’t assign default values to fields that are both required and unique, because uniqueness errors can result. See Default Field Values. |
| Description | Text that describes the custom field. This description is for administration purposes only and doesn’t appear to users on record detail and edit pages that include the field. |
| Display Format | For auto-number fields, enter a Display Format to control formatting details such as the minimum number of leading zeros and any prefix or suffix for the number. Begin by entering the required minimum {0} as a placeholder for the auto-number without any leading zeros. Add any prefix to your number before this placeholder and insert any suffix text after the placeholder. Insert any date prefixes or suffixes in the form of {YY}, {YYYY}, {MM}, or {DD}, which represent the record creation date in Greenwich Mean Time (GMT). For information on using auto-number formats when entering your Display Format, see Auto-Number Formatting Examples. |
| Encrypted | If checked, this custom field is encrypted using Shield Platform Encryption. See Differences Between Classic Encryption and Shield Platform Encryption |
| External Column Name | Available on external objects only. Maps the custom field to an external data source’s table column. For a lookup relationship field, specify the external table column that contains 18-character Salesforce IDs. |
| External ID | For each object that can have custom fields, you can set up to 25 custom auto-number, email, number, or text fields as external IDs. An external ID field contains record identifiers from a system outside of Salesforce. You can use an external ID field to update or upsert records using the API. When using the API or the Data Import Wizard for custom objects and solutions, you can use this field to prevent duplicates by also marking the field as Unique. Custom fields marked as Unique count against an object's limit of 25 External ID fields. Custom indexing that occurs automatically in the background by Salesforce doesn’t count against External ID limits. Not available for external objects. Each external object has an External ID standard field. Its values uniquely identify each external object record in your org. |
| Filter Criteria | The criteria used to select a group of records to calculate the value of a roll-up summary field. |
| Filtering Disabled | For custom fields on external objects, determines whether the field is available in filters. |
| Formulas | Enter the formula for the custom formula field or the custom summary formula for reports. |
| Help Text | The text that appears in the field-level help hover text for this field. |
| Is Name Field | For external object fields of type text, specifies this custom field as the name field for the external object. Not available for text area fields. By default, the External ID standard field is the name field for the external object. If you select this checkbox, make sure that the External Column Name specifies a table column that contains name values. Each external object can have only one name field. For internal use only, Salesforce stores the value of the name field from each row that’s retrieved from the external system. This behavior doesn’t apply to external objects that are associated with high-data-volume external data sources. |
| Label | The name of the custom field as you want it to appear. |
| Latitude and Longitude Display Notation | For geolocation fields, determines how the latitude and longitude notation appears in the Salesforce interface.
For example, the coordinates for San Francisco can be expressed as: Latitude: 37° 46' 30" N, Longitude: 122° 25' 5" W or Latitude: 37.794016°, Longitude: –122.395016° Regardless of the notation you choose to show in the interface, latitude and longitude are stored in Salesforce as decimals. |
| Length (for text fields) | For text fields, the maximum number of characters that a user can enter in a field (up to 255 characters). |
| Length (for number, currency, percent fields) | For number, currency, and percent fields, the number of digits you can enter to the left of the decimal point, for example, 123.98 for an entry of 3. Changing the number of digits (either manually or through workflow rules) can result in truncated values in Salesforce Classic and no value changes in Lightning Experience. This example shows this behavior. In Lightning Experience, the record shows the percentage as 1,235,689.22% and in Salesforce Classic, the percentage appears as 689.22%.
|
| Mask Character | For encrypted text fields, determines the character to use for hidden characters. Available options are * and X. |
| Mask Type | For text fields encrypted with Classic Encryption, determines which characters are hidden and the use of dashes in the field. Masked characters are hidden using the character selected in Mask Character. Available options are:
|
| Master Object | The object on the master side of a master-detail relationship used to show the value of a roll-up summary field. |
| Related List Label | For relationship fields, the title for the related list that shows associated records on the parent record. |
| Related To | For relationship fields, the name of the associated object. |
| Required | Makes the field required everywhere in Salesforce. Not available for external objects. You must specify a Default Value for required campaign member custom fields. Don’t assign default values to fields that are both required and unique, because uniqueness errors can result. See Require Field Input to Ensure Data Quality. |
| Roll-Up Type | For roll-up summary fields, choose the type of calculation to make:
|
| Starting Number | For auto-number fields, enter a Starting Number that’s less than 1 billion. Select Generate Auto Number for existing records to automatically number all current records that begin with the starting number that you enter. If deselected, the next record that you enter is assigned the starting number and your older records are blank in this field. For leads, only unconverted leads are assigned a number. When you create records, the Starting Number value increments to store the number that will be assigned to the next auto-number field created. You can’t edit Starting Number after creating an auto-number field. To edit a Starting Number value, change your auto-number field to a text field and then back to an auto-number field. To restart Starting Number values for fields on objects from a managed package, uninstall and then reinstall the package. Be sure that you don’t create records with duplicate auto-number values. An auto-number field can contain up to 10 digits and up to 20 extra characters for your prefix or suffix.
|
| Sharing Setting | For master-detail relationship fields, the Sharing Setting attribute determines the sharing access that users must have to a master record to create, edit, or delete its associated detail records. |
| Sorting Disabled | For custom fields on external objects, determines whether the field is sortable. |
| Summarized Object | The object on the detail side of a master-detail relationship used to provide the values calculated in a roll-up summary field. |
| Unique | If checked, prevents duplicate field values. For text fields, you can control whether values that are identical except for their case are considered unique. Select Treat "ABC" and "abc" as duplicate values to enforce case-insensitive uniqueness, or select Treat "ABC" and "abc" as different values to enforce case-sensitive uniqueness. Some characters have both single-byte and double-byte versions. For example, all the following characters have single-byte and double-byte versions: “!@#$%^&*(){}[]\|:";',.<>?/~`”. For the purpose of unique field value comparison, the single-byte and double-byte versions of these characters are considered identical. Superscript characters aren’t treated as unique characters. Text such as ABC² and ABC2 are considered identical. Custom fields marked as Unique count against an object's limit of 25 External ID fields. Custom indexing that occurs automatically in the background by Salesforce doesn’t count against External ID limits. |
| Values | For picklist fields, a list of available values (up to 255 characters for each value). For picklists, optionally choose to alphabetize the picklist entries. You can also set the first value as the default selection. If you select both options, Salesforce alphabetizes the entries and then sets the first alphabetized value as the default. For multi-select picklists, enter a list of values, select the sorting options that apply, and then enter how many values you want shown at a time on edit pages. The number of values determines the box height. |
Auto-Number Formatting Examples
Use these examples when setting the display format for auto-number fields.
| Format | Displayed Values |
|---|---|
| {0} | 3 66 103 |
| {000} | 003 066 103 |
| Sample- {00000} | Sample- 00003 Sample- 00666 Sample- 10023 |
| Value- {00} {MM} {DD} {YY} | Value- 03 12 02 04 Value- 76 03 03 04 Value- 123 11 09 04 |
| PO #{0} {MM}-{DD}-{YY} | PO #12233 12-20-04 PO #25 06-07-04 PO #3 07-07-04 |

