The Relationships Pivot Table

Force.com provides “relationship” datatypes that an organization can use to declare relationships (referential integrity) among application objects. When an organization declares an object’s field with a relationship type, the platform maps the field to a Value field in the Data table, and then uses this field to store the ObjID of a related object.

To optimize join operations, Force.com maintains a pivot table called Relationships, as depicted in Figure 8.

Figure 8. The Relationship table helps optimize object joins.

The Relationships index table has two underlying database unique composite indexes (OrgID+GUID, ...

Get The Force.com Multitenant Architecture: Understanding the Design of Salesforce.com’s Internet Application Development Platform now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.