Dr. Codd's Rule for relational databases

Key differences between relational and flat file databases

The information rule

The information rule simply requires all information in the database to be represented in one and only one way, Namely by values in column positions within rows of tables.

The guaranteed access rule

It says that every individual scalar value in the database must be logically addressable by specifying the name of the containing table, the name of the containing column and the primary key value of the containing row.

Systematic treatment of null values

The DBMS is required to support a representation of "missing information and inapplicable information" that is systematic, distinct from all regular values (For example, "distinct from zero or any other number," in the case of numeric values), and is independent of data type.

Active online catalog based on the relational model

The system is required to support an online, inline, relational catalog that is accessible to authorized users by means of their regular query language.

The comprehensive data sub language rule

The system must support at least one relational language that: • has a linear syntax
• can be used both interactively and within application programs
• supports data definition operations (including view definitions)
• data manipulation operations (update as well as retrieval)
• security and integrity constraints
• transaction management operations (begin, commit, and rollback)

The view updating rule

All views that are theoretically updateable must be updateable by the system.

High-level insert, update, and delete

The system must support set-at-a-time INSERT, UPDATE, and DELETE operators.

Physical data independence

Application programs and ad hoc programs are logically unaffected when physical access methods or storage structures are altered.

Logical data independence

Application programs and ad hoc programs are logically unaffected, to the extent possible, when changes are made to the table structures.

Integrity independence

Integrity constraints must be specified separately from application programs and stored in the catalog. It must be possible to change such constraints as and when appropriate without unnecessarily affecting existing applications.

Distribution independence

Existing applications should continue to operate successfully :
• When a distributed version of the DBMS is first introduced;
• When existing distributed data is redistributed around the system.

The nonsubversion rule

If the system provides a low-level (record-at-a-time) interface, then that interface cannot be used to subvert the system (e.g.) bypassing a relational security or integrity constraint.