Bookshelf Home | Contents | Index | PDF |
Configuring Siebel Business Applications > About Tables and Columns > About Siebel Tables > How an Intersection Table Defines a Many-To-Many RelationshipThis topic describes the intersection table. It includes the following topics:
An intersection table is a table that defines a many-to-many relationship. It provides an intersection between two business components. A many-to-many relationship is one in which there is a one-to-many relationship from either direction. For example, there is a many-to-many relationship between Accounts and Contacts. You can view this relationship in the Siebel client:
The two different views can be included in different business objects. The business objects associate the two business components in opposite directions. There is no database construct that directly establishes a many-to-many relationship. Instead, the Siebel schema uses two links and an intersection table to create a many-to-many relationship. Figure 8 illustrates an example of how an intersection table defines a many-to-many relationship. The Type property of an intersection table contains Data (Intersection). You can customize an intersection table with extension columns. You cannot customize an intersection table with custom extension tables. For more information, see About Links. How Siebel CRM Constructs an Intersection Between TablesAn association is a pair of ROW_ID values, where each value references a specific row in the base table of a business component. An intersection table contains one row for each association that exists between the row in the base table of one business component and a row in the base table of another business component. The association row in the intersection table stores the ROW_ID values of the row in the base table of each business component. Figure 9 illustrates how Siebel CRM constructs an intersection. The associations in the intersection table serve the Opportunity/Contact and the Contact/Opportunity links, and their corresponding views. The figure illustrates how the set of object definitions and relationships pertain to one of two links. The other link uses the same set of object types, but with different relationships. Siebel CRM can display one association in both views. For example, the association between Cynthia Smith and Smith Dry Goods. Siebel CRM uses the following objects to construct an intersection:
The Siebel schema uses the following properties of the link specifically to create a many-to-many relationship. These properties are empty for links that do not create a many-to-many relationship: How Siebel CRM Constructs a Many-To-Many RelationshipFigure 10 illustrates how Siebel CRM uses properties in two links to construct a many-to-many relationship. In this example, the relationship is between Opportunities and Contacts. Siebel CRM uses the following objects to construct a many-to-many relationship:
Intersection Data in an Intersection TableAn intersection table contains two foreign key columns that establish a relationship between the records of two business components. It also contains intersection data columns, which are columns that contain data that are specific to the intersection. For example, the S_OPTY_CON table defines the many-to-many relationship between opportunities and contacts, and it includes several data columns in addition to OPTY_ID and PER_ID. These data columns contain information about the combination of a specific opportunity and a specific contact. Some of these columns include:
Some intersection data columns are useful to one parent-child relationship, some are useful to the other parent-child relationship, and some are useful to both of these relationships. For example:
How Siebel CRM Uses an Implicit Join with an Intersection TableTo access an intersection data column, the Siebel schema uses a field in a business component that uses a join. An implicit join exists for any intersection table, and it includes the same name as the intersection table. Siebel CRM creates the implicit join if a link that uses an intersection table is created. It exists for the child business component. For example:
The schema automatically provides the join. This join is not visible in the Object Explorer. This is similar to the implicit join that exists for a one-to-one extension table. You can also use an implicit join to update data. |
Configuring Siebel Business Applications | Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Legal Notices. | |