0% found this document useful (0 votes)
26 views2 pages

Group Work

The document contains tables of student data including student IDs, names, addresses, telephone numbers and grades. It also contains a table of class data including class IDs, module names and professors. Commands are used to print student names, student details including address and telephone, and to join tables to print student details for those with grades over 80 including student ID, name, class name and grade.

Uploaded by

Bánh Bao
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
26 views2 pages

Group Work

The document contains tables of student data including student IDs, names, addresses, telephone numbers and grades. It also contains a table of class data including class IDs, module names and professors. Commands are used to print student names, student details including address and telephone, and to join tables to print student details for those with grades over 80 including student ID, name, class name and grade.

Uploaded by

Bánh Bao
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

TABLE_STUDENTS Student ID S001 S002 S003 Student Name John Jack Alice Address 42 Everton Rd.

43 Eun Tong Sen 12 Middle Road Telephone 87382833 84894977 76878612

TABLE_GRADES Student ID S001 S001 S002 S002 S003 S003 Class ID C02 C03 C01 C02 C01 C03 Grade 77 80 76 81 79 77

TABLE_CLASSES Class ID C01 C02 C03 Module Name Math Phys Chemis Professor Mr.Paul Ms.Loan Mr.Johnathan

A = project (TABLE_STUDENTS) (Student Name) Print A Student Name John Jack Alice

B = ( project (TABLE_STUDENTS) (Address) (Student Name) difference (project (Student ID) (Telephone) ) ) Print B Student Name John Jack Alice Address 42 Everton Rd. 43 Eun Tong Sen 12 Middle Road

R1 = restrict TABLE_STUDENT (Grade >= 80) R2 = join (R1, TABLE_CLASSES : [R1.ClassID# = TABLE_CLASSES.ClassID#]) R3 = join (R2, TABLE_STUDENTS : [R2.StudentID# = TABLE_STUDENTS.StudentID#]) R4 = project R3(StudentID, StudentName, ClassName, FinalGrade) Print R4 StudentID S001 S002 StudentName John Jack ClassName Math Phys Grade 80 81

You might also like