Code360 powered by Coding Ninjas X Naukri.com. Code360 powered by Coding Ninjas X Naukri.com
Last Updated: Jul 9, 2024
Easy

Codd’s rules in DBMS

Author Rohit Kumar
0 upvote
Table of contents
Learn to use AI Tools & ChatGPT to excel as Microsoft SDE
11 Jul, 2024 @ 01:30 PM
Speaker
Pranav Malik
SDE 2 @

Introduction

In Database Management Systems (DBMS), Edgar F. Codd's pioneering work has laid the foundation for modern database design and implementation. Codd's Rules, a set of principles outlined by the computer scientist Edgar F. Codd in the 1970s, serve as fundamental guidelines for evaluating the effectiveness, reliability, and flexibility of DBMS architectures.

In this blog, we embark on a journey to explore Codd's Rules in DBMS, delving into each rule's significance, implications, and practical applications in database design and management.

Codd rules image

Codd Rules are a set of rules that determines whether a given database system is a relational database management system or not. There are, in total, twelve rules, which are known as Codd's Twelve Rules.

A database that follows Codd Rules is a relational database, but what is a relational database, and how is it different from other non-relational database management systems? Let's See.

The 12 Codd’s rules are mentioned below;

  • Rule 0: The Foundation Rule
  • Rule 2: Guaranteed Access Rule
  • Rule 3: Systematic Treatment of NULL values
  • ​​Rule 4: Active Online Catalog
  • Rule 5: The Comprehensive Data SubLanguage Rule
  • Rule 6: View Updating Rule
  • Rule 7: High-level insert, update and delete rule
  • Rule 8: Physical data independence
  • Rule 9: Logical data independence
  • Rule 10: Integrity Independence
  • Rule 11: Distribution Independence
  • Rule 12: Non-Subversion Rule

Rule 1: Information Rule

Everything in the relational database must be stored in a tabular format in a table. And the data stored in the database should be a value in some table's cell.

Rule 2: Guaranteed Access Rule

All the data in the database must be accessible with the help of the primary key value, table name, and column name.

Rule 3: Systematic Treatment of NULL values

The "Systematic Treatment of NULL values," stipulates that a DBMS must support a systematic and uniform means of dealing with missing or undefined data, typically represented by NULL values. This rule ensures consistency in handling NULLs across the database system, promoting data integrity and reliability.

Rule 4: Active Online Catalog

The structural description of the database should be stored in a data dictionary which is an online catalog accessible by authorized users.

Rule 5: Comprehensive Data Sub-language Rule

A relational database supports multiple languages, and to get access to the database, the language must be linear and have a well-defined structure. The language should support data definition, manipulation, and transaction management. It should also support integrity constraints. 

Rule 6: View Updating Rule

Different views of the database must also be updatable by the user. A database view is a subset of a database based on a query that runs on one or more database tables. 

Rule 7: High-level insert, update and delete rule

High-level relational operation in each tuple of a table must be possible. The high-level operations include deletion, updation, and insertion of data. The database should also support operations such as unions and insertions.

Rule 8: Physical data independence

The way the data is accessed by external devices must be independent of the changes being made to the physical structure of the database. For example, if some files supporting the table are moved from one disk to another, it should not affect the application. 

Rule 9: Logical data independence

Any changes made to the database's conceptual schema or the table structure should not modify the data in the applications. For example, if two tables in the database are merged into one table, then the application at the user view should not be affected.  

Rule 10: Integrity Independence

Integrity constraints that are changed at the database level should not enforce modification at the application level. For example, if we use a language such as SQL to enter the data into our table, the database must ensure that the data will not be altered. This makes the database independent of all the applications that use it.

Rule 11: Distribution Independence

The distribution of data must be kept hidden from the end users. And the data should be available to the user even if the data is distributed over multiple locations.

Rule 12: Non-Subversion Rule

Low-level access to data must not be able to bypass the integrity rule to change data. This means that if the database uses any language other than SQL, then that should not violate the integrity rule.

Must Recommended Topic, Schema in DBMSLocked based protocol in DBMS  and  Checkpoint in DBMS.

Frequently Asked Questions

What is the full form of EF Codd?

The full form of EF Codd is Edgar Frank Codd.

What is the Codds law?

 Codd's Law refers to the set of principles proposed by Edgar F. Codd that define the requirements for a database management system to be considered truly relational.

What is the relational model of Codds?

Edgar F. Codd created the relational model, a database model that organises data into tables (relations) with rows and columns and strongly emphasises data integrity and simplicity.

What are the codd rules, and how many codd rules are there?

There are a particular set of rules that each database management system must follow so that it can be considered a relational database management system. This set of rules is called codd rules. And there are 12 codd rules.

Get the tech career you deserve, faster!
Connect with our expert counsellors to understand how to hack your way to success
User rating 4.7/5
1:1 doubt support
95% placement record
Akash Pal
Senior Software Engineer
326% Hike After Job Bootcamp
Himanshu Gusain
Programmer Analyst
32 LPA After Job Bootcamp
After Job
Bootcamp

Conclusion

Congrats, Ninja. You've learned about the codd rules in the database management system. 

You have also learned about what are Relational databases and how they are different from NoSql databases.

We also added some FAQs related to the codd rules.

 

Recommended Reading-

 

Thanks for reading, and please upvote if you liked the article.

 

Also, check out some of the Guided Paths on topics such as Data Structure and AlgorithmsCompetitive ProgrammingOperating SystemsComputer Networks, DBMSand  System Design, etc. as well as some Contests, Test SeriesInterview Bundles, and some Interview Experiences curated by top Industry Experts only on Coding Ninjas Studio.

Happy Learning!!