Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Lab Tasks:Read Three Table join under Module 8 to attempt the 3 a and 3 b of Lab 7 1 . Using MySQL Workbench: Create

Lab Tasks:Read Three Table join under Module 8 to attempt the 3a and 3b of Lab 71. Using MySQL Workbench: Create a new schema for this lab and import Lab07DB.sql. Create a second new schema for this lab and import dept_emp.sql.2. Following the steps in Lab 4: Reverse engineer the first newly created schema. Reverse engineer the second newly created schema.These new models will be needed to perform the following tasks.Before proceeding with tasks 3 and 4, analyze the data in each of the tables and familiarize yourself with the two models.3. For the Lab07DB schema, complete the following requirements:a) Display the professor name, professor program, student first and last names from the studend and professor tables. Referring to the model created in step 2, determine the PK/FK relationships to build the SQL joining the three tables. Sort the data by professor name then by student last name. (A document called Three Table Join for reference)b) Display the professor name and students first and last names who are being mentored. The output should be sorted by professors name, students last name then first name. The Mentor column on the student_professor table determines if a student is being mentored; value of 0= no,1= yes.c) Display all columns from the professor table where the professor is identified as a mentor in the student_professor table. A subquery is to be used to determine the mentor status of a professor. 4. For the dept_emp schema, complete the following requirements:a) Display all contents from the Departments and Employees tables, only employees who are assigned to a department should be displayed.b) Using the same SQL as 4a, modify it to include employees who are not yet assigned to a department.c) Using the same SQL as 4a, modify it to include departments who do not yet have any employees working in it

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

Essentials of Database Management

Authors: Jeffrey A. Hoffer, Heikki Topi, Ramesh Venkataraman

1st edition

133405680, 9780133547702 , 978-0133405682

More Books

Students also viewed these Databases questions