Write the SQL code that counts the number of assignments ordered for each project. Call this returned column as “NUM_of_ASSIGNMENT”. Your query should also show the PROJ_NUM. Only show those projects that ordered more than 1 assignment and revise the order of your table by NUM_of_ASSIGNMENT from high to low. You will use the ASSIGNMENT table.

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question

1) Write the SQL code that counts the number of assignments ordered for each project. Call this returned column as “NUM_of_ASSIGNMENT”. Your query should also show the PROJ_NUM. Only show those projects that ordered more than 1 assignment and revise the order of your table by NUM_of_ASSIGNMENT from high to low. You will use the ASSIGNMENT table. 

**Database Overview: Ch07_ConstructCo**

This document provides a comprehensive view of the Ch07_ConstructCo database, including relational diagrams and detailed tables.

### Relational Diagram

The relational diagram illustrates the structure and relationships among four tables: `JOB`, `EMPLOYEE`, `ASSIGNMENT`, and `PROJECT`. Each table is represented with its fields, and relationships are indicated by connecting lines.

- **JOB:** Contains information about job roles within the company.
- **EMPLOYEE:** Records details about employees.
- **ASSIGNMENT:** Links employees to specific projects and their assigned tasks.
- **PROJECT:** Lists various projects handled by the company.

### Table Descriptions

#### Table Name: `JOB`

| JOB_CODE | JOB_DESCRIPTION        | JOB_CHG_HOUR | JOB_LAST_UPDATE |
|----------|------------------------|--------------|-----------------|
| 500      | Programmer             | 35.75        | 20-Nov-15       |
| 501      | Systems Analyst        | 96.75        | 20-Nov-15       |
| 502      | Database Designer      | 125.00       | 20-Nov-15       |
| 503      | Electrical Engineer    | 84.50        | 20-Nov-15       |
| 504      | Mechanical Engineer    | 67.90        | 20-Nov-15       |
| 505      | Civil Engineer         | 55.78        | 20-Nov-15       |
| 506      | Clerical Support       | 15.25        | 20-Nov-15       |
| 507      | DSS Analyst            | 45.95        | 20-Nov-15       |
| 508      | Applications Designer  | 89.25        | 24-Nov-15       |
| 509      | Bio Technician         | 34.55        | 20-Nov-15       |
| 510      | General Support        | 18.36        | 20-Nov-15       |

#### Table Name: `EMPLOYEE`

| EMP_NUM | EMP_LNAME  | EMP_FNAME | EMP_INITIAL | EMP_HIREDATE | JOB_CODE | EMP_YEARS |
|---------|------------|-----------|-------------|--------------|----------|-----------|
| 101     | News       | John      | G           | 08-Nov-00    | 502      | 12        |
| 102     |
Transcribed Image Text:**Database Overview: Ch07_ConstructCo** This document provides a comprehensive view of the Ch07_ConstructCo database, including relational diagrams and detailed tables. ### Relational Diagram The relational diagram illustrates the structure and relationships among four tables: `JOB`, `EMPLOYEE`, `ASSIGNMENT`, and `PROJECT`. Each table is represented with its fields, and relationships are indicated by connecting lines. - **JOB:** Contains information about job roles within the company. - **EMPLOYEE:** Records details about employees. - **ASSIGNMENT:** Links employees to specific projects and their assigned tasks. - **PROJECT:** Lists various projects handled by the company. ### Table Descriptions #### Table Name: `JOB` | JOB_CODE | JOB_DESCRIPTION | JOB_CHG_HOUR | JOB_LAST_UPDATE | |----------|------------------------|--------------|-----------------| | 500 | Programmer | 35.75 | 20-Nov-15 | | 501 | Systems Analyst | 96.75 | 20-Nov-15 | | 502 | Database Designer | 125.00 | 20-Nov-15 | | 503 | Electrical Engineer | 84.50 | 20-Nov-15 | | 504 | Mechanical Engineer | 67.90 | 20-Nov-15 | | 505 | Civil Engineer | 55.78 | 20-Nov-15 | | 506 | Clerical Support | 15.25 | 20-Nov-15 | | 507 | DSS Analyst | 45.95 | 20-Nov-15 | | 508 | Applications Designer | 89.25 | 24-Nov-15 | | 509 | Bio Technician | 34.55 | 20-Nov-15 | | 510 | General Support | 18.36 | 20-Nov-15 | #### Table Name: `EMPLOYEE` | EMP_NUM | EMP_LNAME | EMP_FNAME | EMP_INITIAL | EMP_HIREDATE | JOB_CODE | EMP_YEARS | |---------|------------|-----------|-------------|--------------|----------|-----------| | 101 | News | John | G | 08-Nov-00 | 502 | 12 | | 102 |
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps

Blurred answer
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY