Homework 2

Homework 2 - MATH department. (A.3) Get S# for students who...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
CSC4402 Homework 2 Due Wednesday 9-23-2009 A. Write Relational Algebra expressions (not SQL) for the following queries with respect to the data- base below(primary key attributes are boldfaced and underlined : D: ( DEPT DNAME BUDGET) for departments T: ( T #TNAME CITY DEPT) for teachers S: ( S #SNAME CITY DEPT DEGREE) for students C: ( C #CNAME DEPT T#) for courses E: ( S # C #GRADE) for enrollments Note: Here MATH , CSC are values of the attribute "DEPT" rather than "DNAME". (A.1) Get S#, SNAME for NewOrleans students from CSC department. (A.2) Get C#, Cname for courses which are taken by a student from
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: MATH department. (A.3) Get S# for students who are either from Baton Rouge or taking the course (C#=) C3 (or both). (A.4) get S#, T# pairs such that the student and the teacher are from the same city and the student takes a course taught by the teacher. (A.5) Get T# for teachers who have taught a course which is NOT taken by any student from Baton Rouge . B. Exercise question 2.5 (page 72) of the text book....
View Full Document

Ask a homework question - tutors are online