Saturday, May 25, 2019

Database Codd Rules


Codd Rules Presentation



DBMS | Relational Model Introduction and Codd Rules

Terminology
Relational Model: Relational model represents data in the form of relations or tables.
Relational Schema: Schema represents the structure of a relation. e.g.; Relational Schema of STUDENT relation can be represented as:
STUDENT (STUD_NO, STUD_NAME, STUD_PHONE, STUD_STATE, STUD_COUNTRY, STUD_AGE)
Relational Instance: The set of values present in relation to a particular instance of time is known as relational instance as shown in Table 1 and Table 2.
Attribute: Each relation is defined in terms of some properties, each of which is known as attribute. For Example, STUD_NO, STUD_NAME, etc. are attributes of relation STUDENT.
The domain of an attribute: The possible values an attribute can take in a relation is called its domain. For Example, the domain of STUD_AGE can be from 18 to 40.
Tuple: Each row of a relation is known as a tuple. e.g.; STUDENT relation given below has 4 tuples.
NULL values: Values of some attribute for some tuples may be unknown, missing or undefined which are represented by NULL. Two NULL values in a relation are considered different from each other.
Table 1 and Table 2 represent the relational model having two relations STUDENT and STUDENT_COURSE.
image
Codd Rules
Codd rules were proposed by E.F. Codd which should be satisfied by relational model.
  1. Foundation Rule: For any system that is advertised as, or claimed to be, a relational data base management system, that system must be able to manage data bases entirely through its relational capabilities.
  2. Information Rule: Data stored in Relational model must be a value of some cell of a table.
  3. Guaranteed Access Rule: Every data element must be accessible by table name, its primary key and name of attribute whose value is to be determined.
  4. Systematic Treatment of NULL values: NULL value in database must only correspond to missing, unknown or not applicable values.
  5. Active Online Catalog: Structure of database must be stored in an online catalog which can be queried by authorized users.
  6. Comprehensive Data Sub-language Rule: A database should be accessible by a language supported for definition, manipulation and transaction management operation.
  7. View Updating Rule: Different views created for various purposes should be automatically updatable by the system.
  8. High level insert, update and delete rule: Relational Model should support insert, delete, update etc. operations at each level of relations. Also, set operations like Union, Intersection and minus should be supported.
  9. Physical data independence: Any modification in the physical location of a table should not enforce modification at application level.
  10. Logical data independence: Any modification in logical or conceptual schema of a table should not enforce modification at application level. For example, merging of two tables into one should not affect application accessing it which is difficult to achieve.
  11. Integrity Independence: Integrity constraints modified at database level should not enforce modification at application level.
  12. Distribution Independence: Distribution of data over various locations should not be visible to end-users.
  13. Non-Subversion Rule: Low level access to data should not be able to bypass integrity rule to change data.





Given the basic ER and relational models, which of the following is INCORRECT?
A. An attribute of an entity can have more than one value
B. An attribute of an entity can be composite
C. In a row of a relational table, an attribute can have more than one value
D. In a row of a relational table, an attribute can have exactly one value or a NULL value
Answer: In relation model, an attribute can’t have more than one value. So, option C is the answer.

No comments:

Post a Comment

Create a Digital Clock using HTML and JavaScript

Create a Digital Clock using HTML and JavaScript  <! DOCTYPE html> < html > < head > <...

Followers

Search This Blog

Popular Posts