# Exclusive relationship (programming)

> Mediated Wiki article. Canonical URL: https://mediated.wiki/source/Exclusive_relationship_(programming)
> Markdown URL: https://mediated.wiki/source/Exclusive_relationship_(programming).md
> Source: https://en.wikipedia.org/wiki/Exclusive_relationship_(programming)
> Source revision: 1150284576
> License: Creative Commons Attribution-ShareAlike 4.0 International (https://creativecommons.org/licenses/by-sa/4.0/)

{{multiple|
{{notability|date=September 2017}}
{{no footnotes|date=September 2017}}
{{refimprove|date=September 2017}}
}}
In computing, an '''exclusive relationship''' is a type of [Relationship](/source/Relational_model) in [computer](/source/computer) [data base](/source/data_base) design.

In Relational Database Design, in some cases the existence of one kind of relationship type precludes the existence of another. Entities within an entity type A may be related by a relationship type R to an entity in entity type B or entity type C but not both. The relationship types are said to be mutually exclusive. Usually, both relationship types will have the same name.

==Example==

A Data (Entity A) could be Sent (Relationship Name) to a Monitor (Entity B) or a Printer (Entity C) to be shown. In this case, the relationship between the Monitor and Printer at one side and Data at the other side is an Exclusive Relationship. Of course it is assumed that Data could be sent to only one of the targets at a time, not to both.

      --- Sent_To ---> Monitor
  Data 
      --- Sent_To ---> Printer

==References==

* Jan L. Harrington, Relational Database Design Clearly Explained, Morgan Kaufmann, 2002, {{ISBN|1-55860-820-6}}, pages 354-355

Category:Database theory

{{Comp-sci-stub}}

---
Adapted from the Wikipedia article [Exclusive relationship (programming)](https://en.wikipedia.org/wiki/Exclusive_relationship_(programming)) by Wikipedia contributors ([contributor history](https://en.wikipedia.org/wiki/Exclusive_relationship_(programming)?action=history)). Available under [Creative Commons Attribution-ShareAlike 4.0 International](https://creativecommons.org/licenses/by-sa/4.0/). Changes may have been made.
