Navigating a Relationship from Two Directions

Meta Data Services Programming

Meta Data Services Programming

Navigating a Relationship from Two Directions

You can navigate a relationship from the direction of either the origin or destination object. As such, there are always two ways to navigate every relationship.

In the following example, you can navigate from Table to Column, or you can navigate from Column to Table. This figure shows the direction of navigation from the Table object to a Column object, using a Columns collection. When navigating from a Table object to a Column object, you use a Columns collection. The navigation and subsequent manipulation is always through the collection. For example, from the Columns collection, you can select a column, retrieve or set a column property, add or delete a new column, and so on.

In the next figure, the direction of the navigation is from a Column object to the Table object. Each Column object accesses a separate Table collection to navigate back to the Table. The same origin-destination relationship between the Table origin object and the Column destination object supports this alternate approach to navigation. Typically, a relationship from a destination object to an origin object is called a reverse relationship. Furthermore, you can treat this relationship as a separate entity (for example, as a column containedBy table relationship).

See Also

Navigating a Relationship Using Two Approaches

Navigating a Repository

Navigation Overview