🎙 Free live masterclass · Sun, 29 Nov, 7:00 pm IST · Java Full Stack roadmap Register free →
Skills101
← All topics

Quiz: Relational Algebra: questions with answers

15 questions, each with the answer and a short explanation.

Take the timed quiz + get a certificate →
  1. Q1. Which relational algebra operator corresponds to the WHERE clause?
  2. Q2. A table has 10 rows. π dept (table) returns 4 rows. Why?
  3. Q3. R has 5 rows and S has 3 rows. How many rows does R × S have?
  4. Q4. What condition must two relations meet before you can take their union?
  5. Q5. "Find suppliers who supply every part." Which operator fits this query?
  6. Q6. Which of these is a derived operator (it can be written using the basic ones)?
  7. Q7. A = {1, 2, 3} and B = {2, 3, 4}. What is A − B?
  8. Q8. Why do query optimizers push selections below joins?
  9. Q9. When do you need the rename operator ρ?
  10. Q10. How can intersection be written with set difference only?
  11. Q11. Which SQL keyword matches the set difference operator (−)?
  12. Q12. With DB = {1, 2, 3} and OS = {1, 3, 4} (roll numbers), what is OS − DB?
  13. Q13. How is a theta join R ⋈θ S defined using the basic operators?
  14. Q14. Which SQL query matches π name, city (σ cgpa 8 (students))?
  15. Q15. What does the "closure" property of relational algebra mean?