distinct names of all students in Relational Algebra

Consider the following relational schema.

  • Students(rollno: integer, sname: string)
  • Courses(courseno: integer, cname: string)
  • Registration(rollno: integer, courseno: integer, percent: real)

Query : “Find the distinct names of all students who score more than 90% in the course numbered 107” 

How's the below query returning correct solution ??

{T∣∃S∈Students,∃R∈Registration(S.rollno=R.rollno∧R.courseno=107∧R.percent>90∧T.sname=S.sname)}

When i write  "{T |  " --> should'nt we define T as which relation tuple (like ∃T∈ Students) it is ..?? like we did for S and R in above query.

 

0Comment