Friday, October 30, 2015

Relational Algebra: Project Operator



The Project Operation

The project operation helps to filter out some of the attributes of a relation. In other words we can select part of the attributes of a relation using project operation. Projection is denoted by the uppercase Greek letter pi (Π). We list those attributes of a relation we wish to appear in the result as a subscript to Π. The relation appears in parenthesis after the projection.

If we wish to list all loan numbers and amount of the loans for the loan relation, we write:





Consider the more complicated query “Find those customers who live in Dhaka city”. We write:
 


This query is a composition of the relational operations of both select and projection.





         



No comments:

Post a Comment