How Relationships Conform to Relationship Types
When you store a relationship, the meaning of what you store answers three questions:
- Which two objects are related to each other?
For example, when you store the relationship indicating that Herman Melville wrote Moby Dick, you relate the object describing Herman Melville and the object describing Moby Dick.
- How are the two objects related?
For example, when you store the relationship indicating that Herman Melville wrote Moby Dick, you indicate that Melville wrote the book, not that he reads it or criticizes it. You indicate that Melville wrote the book by creating a relationship that conforms to the Authorship relationship type.
- What role does each object play in the relationship?
For example, when you store the relationship indicating that Herman Melville wrote Moby Dick, you indicate that Melville wrote Moby Dick, not that Moby Dick wrote Melville. The object representing Melville plays the role of the writer and the object representing Moby Dick plays the role of the thing that was written.
The following figures evaluate whether potential relationships conform to the two relationship types: Authorship (of book by person) and Publication (of book by publisher).
Potential relationship
The following diagram shows the potential relationship based on relationship type.
Does the relationship conform?
Microsoft PressĀ® publishes Inside OLE: Yes, the relationship conforms to the Publication relationship type.
Potential relationship
The following diagram shows a potential relationship that does not conform to relationship type.
Does the relationship conform?
Kraig Brockschmidt publishes Inside OLE: No, the relationship does not conform to either relationship type. The Publication relationship type allows you to save a relationship indicating that a publisher publishes a book. This data indicates that a person publishes a book.
Potential relationship
The following diagram shows the potential relationship based on relationship type.
Does the relationship conform?
Kraig Brockschmidt wrote Inside OLE: Yes, the relationship conforms to the Authorship relationship type.
Potential relationship
The following diagram shows a potential relationship that does not conform to relationship type.
Does the relationship conform?
Inside OLE publishes Microsoft Press: No, the relationship does not conform to either relationship type. Although this relationship uses two objects of the correct type, it does not conform because it places those objects in the wrong roles.
Potential relationship
The following diagram shows the potential relationship based on relationship type.
Does the relationship conform?
Microsoft Press publishes Moby Dick: Yes, the relationship conforms to the Publication relationship type. The relationship conforms, even though the data is inaccurate. (Microsoft Press does not publish Moby Dick.)