Write the SQL queries that accomplish the following tasks in the HAFH Realty Company Property Management Database:

Question:

Write the SQL queries that accomplish the following tasks in the HAFH Realty Company Property Management Database:
a. Display the SMemberID and SMemberName for all staff members.
b. Display the CCID, CCName, and CCIndustry for all corporate clients.
c. Display the BuildingID, BNoOfFloors, and the manager’s MFName and MLName for all buildings.
d. Display the MFName, MLName, MSalary, MBDate, and number of buildings that the manager manages for all managers with a salary less than $55,000.
e. Display the BuildingID and AptNo, for all apartments leased by the corporate client WindyCT.
f. Display the InsID and InsName for all inspectors whose next inspection is scheduled after 1-JAN-2014. Do not display the same information more than once.
g. Display the SMemberID and SMemberName of staff members cleaning apartments rented by corporate clients whose corporate location is Chicago. Do not display the same information more than once.
h. Display the CCName of the client and the CCName of the client who referred it, for every client referred by a client in the music industry.
i. Display the BuildingID, AptNo, and ANoOfBedrooms for all apartments that are not leased.
Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Related Book For  book-img-for-question

Database Systems Introduction to Databases and Data Warehouses

ISBN: 978-0132575676

1st edition

Authors: Nenad Jukic, Susan Vrbsky, Svetlozar Nestorov

Question Posted: