Computer Science Engineering (CSE) Exam  >  Computer Science Engineering (CSE) Test  >  GATE Computer Science Engineering(CSE) 2027 Mock Test Series  >  Test: Relational Algebra, Tuple Calculus & SQL- 1 - Computer Science Engineering (CSE) MCQ

GATE Computer Science Engineering(CSE) 2027 Test: Relational Algebra, Tuple


MCQ Practice Test & Solutions: Test: Relational Algebra, Tuple Calculus & SQL- 1 (10 Questions)

You can prepare effectively for Computer Science Engineering (CSE) GATE Computer Science Engineering(CSE) 2027 Mock Test Series with this dedicated MCQ Practice Test (available with solutions) on the important topic of "Test: Relational Algebra, Tuple Calculus & SQL- 1". These 10 questions have been designed by the experts with the latest curriculum of Computer Science Engineering (CSE) 2026, to help you master the concept.

Test Highlights:

  • - Format: Multiple Choice Questions (MCQ)
  • - Duration: 30 minutes
  • - Number of Questions: 10

Sign up on EduRev for free to attempt this test and track your preparation progress.

Test: Relational Algebra, Tuple Calculus & SQL- 1 - Question 1

The relational algebra expression equivalent to the following expression:
 is:

Detailed Solution: Question 1

The expression

can be represented in relational algebra as

It says that select those rows from relation r where A = 10 union where B = 20.
Hence option (b) is correct.

Test: Relational Algebra, Tuple Calculus & SQL- 1 - Question 2

A relation (from the relational database model) consists of a set of tuples, which implies that

Test: Relational Algebra, Tuple Calculus & SQL- 1 - Question 3

Which of the following statements is correct with respect to entity integrity?

Detailed Solution: Question 3

According to entity integrity primary key of relation should not contain null values.

Test: Relational Algebra, Tuple Calculus & SQL- 1 - Question 4

Which of the following operations is not part of the five basic set operations in relational algebra?

Detailed Solution: Question 4

Five primitive operators of Codd’s algebra are the selection, the projection the Cartesian product, the set union and the set difference.

Test: Relational Algebra, Tuple Calculus & SQL- 1 - Question 5

Which of the following relational algebra operations is not a commutative operation?

Detailed Solution: Question 5

Option D is correct.

Union and Intersection are binary set operations and are commutative; that is, R ∪ S = S ∪ R and R ∩ S = S ∩ R.

Selection (σ) and Projection (π) are unary operators. Multiple selections commute with each other and multiple projections commute with each other, but projection does not in general commute with selection; changing their order can change the result.

For example, let R(A, B) be a relation. Compare π_A(σ_{B > 10}(R)) and σ_{B > 10}(π_A(R)). The first returns the A values of tuples where B > 10. The second is invalid or empty because B has been removed by the projection, so the selection condition B > 10 cannot be applied after projection. Thus the order matters.

Because the question asks for a single operation among the options that is not commutative in the usual sense used in relational-algebra discussions (i.e., it does not commute with selection in general), Projection (Option D) is chosen as the correct answer.

Test: Relational Algebra, Tuple Calculus & SQL- 1 - Question 6

Consider a banking database with the following relation with three attributes loans (br_name, loan_no, amount).
Find the appropriate query for the given statements below:
“Find the loan number for each loan of an amount greater than 20000”

Detailed Solution: Question 6

Loans (br_name, loan_no, amount)
For the query “find the loan number for each loan of an amount greater than 20000”.
We have to check for each loan to find a loan number which is greater than 20,000.

Hence (b) is the correct option.

Test: Relational Algebra, Tuple Calculus & SQL- 1 - Question 7

Let R(a, b, c) and S(d, e, f) be two relations in which d is the foreign key of S that refers to the primary key of R. Consider the following four operations R and S
1. Insert into R
2. Insert into S
3. Delete from R
4. Delete from S
Which of the following is true about the referential integrity constraint above?

Detailed Solution: Question 7

Referential integrity constraint: In relational model, two relation are related to each other over the basis of attributes, Every value of referencing attribute must be null or be available in the referenced attribute.

Here d is the foreign key of S that refers to the primary key of R.
1. Insert into R will not cause any violation.
2. Insert into S may cause violation because for each entry in ‘S ’ it must be. in ‘R ’ .
3. Delete from R may cause violation because for the deleted entry in R there may be referenced entry in the reIation S.
4. Delete from S will not cause any violation. 
Hence (d) is the correct option.

Test: Relational Algebra, Tuple Calculus & SQL- 1 - Question 8

Let r and s be two relations over the relation schemes R and S respectively, and let A be an attribute in R. Then the relational algebra expression   is always equal to 

Detailed Solution: Question 8

The relational algebra expression:

Hence (c) is the required option.

Test: Relational Algebra, Tuple Calculus & SQL- 1 - Question 9

Join Selectivity of a relation R in a natural join with a relation S is the _____

Test: Relational Algebra, Tuple Calculus & SQL- 1 - Question 10

Which of the following is wrong?

Detailed Solution: Question 10

  is not equivalent because θ join is not cumulative hence the entries in   may not be same. Hence option (d) is correct.

56 docs|215 tests
Information about Test: Relational Algebra, Tuple Calculus & SQL- 1 Page
In this test you can find the Exam questions for Test: Relational Algebra, Tuple Calculus & SQL- 1 solved & explained in the simplest way possible. Besides giving Questions and answers for Test: Relational Algebra, Tuple Calculus & SQL- 1, EduRev gives you an ample number of Online tests for practice
Download as PDF