Question: Lab #8: 1:1 and Recursive SQL Queries Create the queries to answer the following business questions/tasks and submit your queries to Moodle in one single
Lab #8: 1:1 and Recursive SQL Queries
Create the queries to answer the following business questions/tasks and submit your queries to Moodle in one single .sql script named "LAB8_firstname_lastname".
NOTE: Make sure your code is correct and executable. Non-executable code will receive 0 points.
**Use SQL code to answer the following queries**
Part I. - 1:1 Recursive
In Part I, you will practice querying the text database on the MySQL server. You will need to use the Monarch table.
(1pt) List monarch type, name, and number of the predecessor of Queen Victoria I.
(1pt) List monarch type, name, and number of the successor of Queen Victoria I.
Part 2. - 1:M Recursive
In Part 2, you will practice querying the text database on the MySQL server. You will need to use the emp table.
(1pt) List the first names and salaries of employees who are a boss.
(1pt) List all the employees (name and salary) who are managed by Alice.
(1pt) For each boss, list the average salary of the employees who work for him or her. Include the first name of the boss.
Part 3. - M:M Recursive
In Part 3, you will practice querying the patent database on the MySQL server. You will need to use the citation and patents tables.
(1pts) Find out which patents are citing patent No. 3992014.
(2pts) Find out which patents are citing patent No. 3992014. List the category and applied year of the citing patents.
(2pts) Find out which patents are citing patent No. 3992014. List the category and applied year of both cited and citing patents.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
