Newer Version Available

This content describes an older version of this product. View Latest

FieldHistoryArchive

Represents field history values for all objects that retain field history. This object is available only to users with the “Retain Field History” permission. This object is available in API version 29.0 and later. Each instance of the FieldHistoryArchive object represents a single change in the value of a field. The FieldHistoryArchive can store history for both standard and custom fields. The Field field returns the name of the field unless the parent field or object is deleted, in which case it returns the ID and you can retrieve the old field and object name from the FieldNameAfterArchival and ParentNameAfterArchival fields, respectively.

Supported Calls

describeSObjects()query()

Fields

Field Name Details
ArchiveFieldName
Type
string
Properties
Nillable
Description
The name of the field at the time the data was archived. This may not be the same for all records related to a single field, if the field name changed.
ArchiveParentName
Type
string
Properties
Nillable
Description
The name of the parent object at the time the data was archived. This may not be the same for all records related to a single field, if the object name changed.
ArchiveParentType
Type
string
Properties
Nillable
Description
The type of the field at the time the data was archived. This may not be the same for all records related to a single field, if the field type changed.
ArchiveTimestamp
Type
dateTime
Properties
Nillable
Description
The date and time at which the data was archived.
CreatedById
Type
dateTime
Properties
Nillable
Description
The user ID of the user who created the archive.
CreatedDate
Type
dateTime
Properties
Nillable
Description
The date and time at which the archive was created.
Field
Type
picklist
Properties
Filter, Nillable, Restricted picklist
Description
The name of the field that was changed. If the field is deleted from the parent object, the Field field contains the ID instead.
FieldHistoryType
Type
picklist
Properties
Nillable, Restricted picklist
Description
The name of the object that contains the field history (for example, Account).
Id
Type
ID
Properties
Defaulted on create, Filter, idLookup
Description
The ID of the archived record. It’s useful to have a field’s ID for fields that you may have deleted. (Field names aren’t retained in history when you delete fields from Salesforce.)
NewValue
Type
anyType
Properties
Nillable
Description
The new value of the modified field.
OldValue
Type
anyType
Properties
Nillable
Description
The previous value of the modified field.
ParentId
Type
reference
Properties
Filter, Nillable
Description
The ID of the object that contains the field (the parent object).