Be Careful
Both the
_options_
andcontrollerField
fields below can be updated, but their previous values will be overwritten. This means the current options or controlling field settings will be permanently erased and replaced with the new data you've set.For example, you may have a picklist field which includes the options "A", "B", and "C". If you use the update method below to add the "D" option, your field will permanently delete the "A", "B", and "C" options and include only the "D" option.
To add the "D" option via API, you must also add the previous "A", "B", and "C" options, including all their settings. Before starting, get the current
value
field for each of your options, and then set each option with the relevantvalue
. If you do not use the same values, the update action will cause records to change or lose the value they currently have set in this field.
Please Note
The number value of each picklist option must be a unique value for the picklist, and only exist once per picklist. Options in different picklists can have the same number value.