by Dinesh Thakur Category: RDBMS

Relational Algebra is a procedural language that can be used to tell the DBMS how to build a new relation from one or more relations in the database and the Relational Calculus is a non-procedural language that can be used to formulate the definition of a relation in terms of one or more database relations.

While using the relational algebra, user has to specify what is required and what are the procedures or steps to obtain the required output whereas in Relational Calculus user just specifies what is required and need not to specify how to obtain it. Both the relational algebra and the relational calculus are formal, non-user-friendly languages. They have been used as the basis for other, higher-level Data Manipulation Languages (DMLs) for relational databases. They illustrate the basic operations required of any DML and serve as the standard of comparison for other relational languages.

The relational algebra is a theoretical language with operations that work on one or more relations to define another relation without changing the original relation(s). Thus, both the operands and the results are relations, and so the output from one operation can become the input to another operation. This allows expressions to be nested in the relational algebra, just as we can nest arithmetic operations. This property is called closure: relations are closed under the algebra, just as numbers are closed under arithmetic operations.

There are many variations of the operations that are included in relational algebra. Codd originally proposed eight operations, but several others have been developed. The five fundamental operations in relational algebra, Selection, Projection, Cartesian product, Union and Difference, perform most of the data retrieval operations, which can be expressed in terms of the five basic operations.

In relational algebra each operation takes one or more relations as its operand(s) and another relation as its result. Consider an example of mathematical algebra as shown below

**3+5=8**

Here, 3 and 5 are operands and + is an arithmetic operator which gives 8 as the result.

Similarly, in relational algebra, RI + R2 = R3

Here RI, R2 are relations (operands) and + is relational operator which gives R3 as a resultant relation.

**Comparison Between Relational Algebra and Relational Calculus**

Relational Algebra defined by using the eight basic operators, Codd then went on to define a Relational Calculus. Here, is a comparison of Relational Algebra and relational Calculus:

Related Articles (You May Also Like)

About Dinesh Thakur

Dinesh Thakur holds an B.SC (Computer Science), MCSE, MCDBA, CCNA, CCNP, A+, SCJP certifications. Dinesh authors the hugely popular Computer Notes blog. Where he writes how-to guides around Computer fundamental , computer software, Computer programming, and web apps. For any type of query or something that you think is missing, please feel free to Contact us.

Search Content

Popular Article

#### What is File Organizations? Types of File Organization.

#### What is Transaction in DBMS? Explain Process,States and Properties of Transaction.

#### What is Lock? Type of Lock in DBMS.

#### Fifth Normal Form(5NF)

#### Boyce-Codd Normal Form (BCNF)

#### Fourth Normal Form (4NF)

#### What is Key? Type of Key.

#### What are Relational Algebra and Relational Calculus?

#### What is Relational Calculus

#### What are the RDBMS Components?

#### How to Deadlock Detect and Recover.

#### What is Database Design Methodology? Different Phases of Design Methodology.

#### Types of Relational Operators

#### First Normal Form (1NF)

#### How to Handling a Deadlocks?

#### Third Normal Form (3NF)

#### What is Lock Granularity?

#### What are the CODD’S Rules in RDBMS ?

#### Second Normal Form (2NF)

#### Concurrent Control Algorithms

#### What is Denormalization

#### What is Starvation During Granting of Locks

Basic Courses

Advance Courses