- Consider The Following Schema Classroom Building Room Number Capacity Department Dept Name Building Budget Cours 1 (426.91 KiB) Viewed 36 times
Consider the following schema classroom (building, room_number, capacity) department (dept_name, building, budget) cours
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am
Consider the following schema classroom (building, room_number, capacity) department (dept_name, building, budget) cours
Consider the following schema classroom (building, room_number, capacity) department (dept_name, building, budget) course(course_id, title, dept_name, credits) instructor(ID, name, dept_name, salary) section (course_id, sec_id, semester, year, building, room_number, time_slot_id) teaches(ID, course_id, sec_id, semester, year) student (ID, name, dept_name, tot_cred) takes(ID, course_id, sec_id, semester, year, grade) advisor(s_ID, i_ID) time_slot(time_slot_id, day, start_time, end_time) prereq(course_id, prereq_id) (i) write a SQL function that takes nothing as parameter but returns number of records in cross join between instructor and department tables. (ii) Considering above schema, create a view which will allow corresponding users to see only name of the department with total salary of instructors of corresponding department. [6 points] [ 4 points]