Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write the following queries in SQL, using the university schema. classroomfbuilding, room number, capacity) departmentfdept name, building, budget) course(course id, title, dept name, credits) instructorQD,

image text in transcribed

Write the following queries in SQL, using the university schema. classroomfbuilding, room number, capacity) departmentfdept name, building, budget) course(course id, title, dept name, credits) instructorQD, name, dept name, salary) sectionfcourse id, sec id, semester, year, building, room number, time slot id) teachesQD, course id, sec id, semester, year) studentQD, name, dept name, tot cred) takesQD, course id, sec id, semester, year, grade) advisor(s ID, i ID) time slotftime slot id, day, start time, end time) forereqfcourse id, prereq id) Find the titles of courses in the Comp. Sei. department that have 3 credits. Find the names of all students who have taken at least one Comp. Sei. course; make sure there are no duplicate names in the result Find the maximum enrollment, across all sections, in Autumn 2009. Find the IDs and names of all students who have not taken any course offering before spring 2009 Increase the salary of each instructor in the Comp. Sei. department by 10%. Delete all courses that have never been offered (that is, do not occur in the section relation). Insert every student whose tot cred attribute is greater than 100 as an instructor in the same department, with a salary7 of $10,000. Create a new course "CS-001", titled "Weekly Seminar",with 0 credits. Create a section of this course in autumn 2009, with sec id of 1. Enroll every student in the Comp. Sei. department in the above

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Probabilistic Databases

Authors: Dan Suciu, Dan Olteanu, Christopher Re, Christoph Koch

1st Edition

3031007514, 978-3031007514

More Books

Students also viewed these Databases questions

Question

How many Tables Will Base HCMSs typically have? Why?

Answered: 1 week ago

Question

What is the process of normalization?

Answered: 1 week ago