What is the difference between covering and overlapping constraints use in DBMS?

migrated from stackoverflow.com Apr 2 '14 at 3:10

This question came from our site for professional and enthusiast programmers.


In reference with below Employee Entity Relational Model

enter image description here

  • Overlap Constraints : Can "Karthik" (employee) be an Hourly_Emps as well as a Contract_Emps entity? (Allowed/Disallowed) - In this scenario the hourly employee karthik cannot be a contract employee - Disallowed - This explains the Overlap constraints.

  • Covering Constraints : Is every hourly employee and every contract employee an employee of this organization? Answer: Yes, all the contract/hourly employees belong to the master employees entity - This explains the Covering constraints.


Overlap Constraints: It determines whether XYZ person be both an hourly_emp and a contract_emp? Answer is NO. Can he be both a contract_emp and a senior emp emtity? Answer is YES. So we can write something like this. 'Contract_emp OVERLAPS Senior_emp' In the absence of such a statement, we assume by default that entity sets are constrained to have no overlap. Overlapping constraint is kind of allowed or not allowed.

Covering Constraints: We might want to identify the set of entities that participate in some relationship. For e.g. We want to define Manages relationship so that participant entity sets are Senior_emps and Departments, to ensure that "ONLY SENIOR EMPLOYEES CAN BE MANAGERS." As another example, Motorboats and Cars may have different descriptive attributes (say, tonnage and number of doors), but as Motor Vehicles entities, they must be licensed. The licensing information can be captured by a Licensed To relationship between Motor Vehicles and an entity set called Owners.


Covering Constraints

determine whether the entities in the subclass collectively include all entities in the superclass

Overlapping Constraints

determine whether two subclasses are allowed to contain the same class entity

See: "Database Management Systems" by Ramakrishnan and Gehrke. 2nd or 3rd edition.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.