Relationships
Provides metadata describing how tables and records are related within SugarCRM. This view supports data modeling, dependency mapping, and relational schema analysis.
Columns
| Name | Type | Description |
| Name | String | The name of the relationship. This value uniquely distinguishes the relationship definition within the system. |
| DynamicSubpanel | String | The dynamic subpanel that is associated with this relationship. This value determines how the relationship is displayed within the user interface. |
| JoinKeyLhs | String | The join key value on the left-hand side of the relationship. This field identifies the column that is used to establish the relationship from the left module. |
| JoinKeyRhs | String | The join key value on the right-hand side of the relationship. This field identifies the column that is used to establish the relationship from the right module. |
| JoinTable | String | The name of the join table that links the left and right modules in the relationship. This table stores the cross-referenced relationship records. |
| LhsKey | String | The key column on the left-hand side module that participates in the relationship. This value is used to establish linkage and matching logic. |
| LhsModule | String | The module on the left-hand side of the relationship. This value identifies the primary module that participates in the relationship. |
| LhsTable | String | The database table that corresponds to the left-hand side module. This value determines where the left module's records are stored. |
| RelationshipRoleColumn | String | The column that determines a role-based variation of the relationship. This value enables conditional or filtered relationship behavior. |
| RelationshipRoleColumnValue | String | The value of the role column that activates or defines the relationship's scope. This value is used to enforce role-specific linking conditions. |
| RelationshipType | String | The relationship type (for example, 'one-to-one', 'one-to-many', or 'many-to-many'). This value indicates how records are associated across modules. |
| PrimaryFlagColumn | String | The column that indicates the primary record in a group of related records. This value helps determine which record should be treated as dominant or preferred. |
| PrimaryFlagDefault | String | The default value that is applied to the primary flag column when no explicit value is defined. This value establishes baseline relationship behavior. |
| PrimaryFlagSide | String | The side of the relationship on which the primary flag applies (for example, 'left' or 'right'). This value identifies which module determines primary status. |
| RhsKey | String | The key column on the right-hand side module that participates in the relationship. This value is used to establish linkage and matching logic. |
| RhsModule | String | The module on the right-hand side of the relationship. This value identifies the secondary module that participates in the relationship. |
| RhsTable | String | The database table that corresponds to the right-hand side module. This value determines where the right module's records are stored. |
| TrueRelationshipType | String | The underlying system relationship type that governs actual linking behavior, which can differ from the displayed relationship type for legacy or UI purposes. |
| UserField | String | The name of the user field that is associated with the relationship. This value can be used to track ownership, assignment, or user-specific metadata within the relationship. |