Overview of the Chatter Data Model

Chatter posts, comments, and the list of records followed in Chatter are stored in standard database objects, accessible in SOQL, SOSL, Apex code, the Web Services API, and generally anywhere you need them. With this developer-friendly approach, you can build any number of interesting Chatter-aware programs. You can automatically follow a set of records based on user actions, batch process posts and comments to identify patterns, build an alternative user interface for Chatter, and even extend Chatter outside of your organization by integrating it with external applications.

After you have a good grasp of the data model, all of these scenarios are trivial to implement on the platform. But compared with the standard platform objects such as Contacts and Accounts, Chatter has a slightly more complex data model, including objects with some distinctive qualities, summarized here:

Image Dynamic—The objects in the Chatter schema can appear and disappear based on the Chatter configuration. For example, when Chatter is disabled in an organization, the Chatter objects are completely hidden, as if they never existed. Also, objects containing Chatter posts are dynamically created when Chatter is enabled for a custom object.

Image Relationship-rich—The whole purpose of Chatter is to link social and business data, so Chatter objects consist primarily of foreign keys to other objects.

Image Designed for high volume—Chatter objects usually do not allow records to be updated. Some objects can’t even be queried directly and must be referenced indirectly from a parent object.

This section introduces you to the Chatter data model by exploring these four areas:

Image Chatter posts—Learn how to query, create, and delete the three main types of Chatter posts, based on the parent record’s object type.

Image Feed-tracked changes—Feed-tracked change records are created automatically by Force.com to provide an audit trail of database activity. They can be queried but never directly created, updated, or deleted.

Image Chatter comments—You can query, create, and delete Chatter comments, given a parent post.

Image Followed records—Get a list of followers for a record, and follow and unfollow records by creating and deleting simple Chatter configuration records.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.218.123.227