Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Question 3 Given below are the relational database schemas for Employee, Aircraft, Flight and Certified Staff. Employee (emp No, empName, salary) Aircraft (aircraftNo, aName, aModel,

image text in transcribed

Question 3 Given below are the relational database schemas for Employee, Aircraft, Flight and Certified Staff. Employee (emp No, empName, salary) Aircraft (aircraftNo, aName, aModel, flying Range, capacity) Flight (flightNo, aircraftNo, from, to, flightDistance, departTime, arriveTime) CertifiedPilot (empNo, aircraftNo) Write the SQL statements to: i) List all aircraft alphabetically by its name. ii) List all Airbus aircraft that can cover the capacity between 100 to 220 seats. iii) List the names of pilots certified for Boeing aircraft. iv) Find the number of employee with the highest salary. v) List the aircraft's details assign for flight number MH138. Question 4 Given below are the relational database schemas for Staff, Product, Customer and Service. Staff (staffNo, staffName, position, phoneNo) Product (prodNo, prodName, price, quantity) Customer (custNo, custName, address, phoneNo) Service (serviceNo, prodNo, custNo, description, type, dateServiced, staffNo) Write the SQL statements to: i) List all products that cost less than RM100.00 ii) List all staff that work as clerk or supervisor. iii) Find the number of product serviced by staff number S1155. iv) List the customer's name and product's name for product serviced on 15/08/2012. v) Change the product's price from RM100.00 to RM60.00 for product number P555. vi) List all customers that live in Kajang. Question 5 Given below are the relational database schemas for Table Student, Subject and Lecturer. Student(studID, name, address, dob, gender) Subject(subjectCode, subjectName, section, studID, lecturerID) Lecturer(lecturerID, lecturerName, Dept, gender, salary) i) List all the details of male students. ii) List the detail of subjects registered by the student with number P125. iii) List all students' name taught by a lecturer named Saadiah. iv) Find the average of lecturer's salary alphabetically ordered by Department. v) List the lecturer's name and the subject name for Database Management

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

PC Magazine Guide To Client Server Databases

Authors: Joe Salemi

1st Edition

156276070X, 978-1562760700

More Books

Students also viewed these Databases questions

Question

6. Identify the belly of the whale in Raiders of the Lost Ark.

Answered: 1 week ago

Question

7. What decisions would you make as the city manager?

Answered: 1 week ago

Question

8. How would you explain your decisions to the city council?

Answered: 1 week ago