2

I am trying to insert a Chatter FeedItem through Data Loader. When the type is 'TrackedChange', I am getting the error

'Cannot directly insert FeedItem with type 'TrackedChange'.

How can I solve this issue?

  • Tracked changes are for field history tracking chatter feeds thus they maintain audit logs and thus wount be allowed to be inserted by SF to maintain integrity of data. – Pranay Jaiswal Nov 6 '18 at 10:14
3

You won't be able to insert a FeedItem with Type TrackedChange.

The documentation states that you cannot create a FeedItem with all Type values, but only few. Below is an excerpt from the Type field's description:

The type of FeedItem. Except for ContentPost, LinkPost, and TextPost, don’t create FeedItem types directly from the API.

A FeedItem with Type TrackedChange will be automatically created if there are fields available in the feed item for the Object, for which the feed was generated, being tracked as part of audit history. This will also indirectly create the FeedTrackedChange record capturing the field changes.

TrackedChange — a change or group of changes to a tracked field.

Furthermore, FeedTrackedChange object itself is not creatable from APIs.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.