Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Using these already created tables in a database, write Microsoft SQL Server compatible SQL queries to answer each question. No written response needed, just the

image text in transcribed

image text in transcribed

Using these already created tables in a database, write Microsoft SQL Server compatible SQL queries to answer each question. No written response needed, just the SQL code that answers the question.

I. How many projects are being run by the marketing department? Be sure to assign an appropriate column name to the computed results.

J. What is the total MaxHours of projects being run by the marketing department? Be sure to assign an appropriate column name to the computed results.

K. What is the average MaxHours of projects being run by the marketing department? Be sure to assign an appropriate column name to the computed results.

L. How many projects are being run by each department? Be sure to display each DepartmentName and to assign an appropriate column name to the computed results.

PROJECT: ProjectID ProjectName Department MaxHours StartDate EndDate 1 1000 2014 Q3 Product Plan Marketing 135.00 2014-05-10 2014-06-15 2 1100 2014 Q3 Portfolio Analysis Finance 120.000 2014-07-05 2014-07-25 3 1200 2014 Q3 Tax Preparation Accounting 145.00 2014-08-10 2014-10-15 4 1300 2014 Q4 Product Plan Marketing 150.00 2014-08-10 2014-09-15 5 1400 2014 Q4 Portfolio Analysis Finance 140.00 2014-10-05 NULL ASSIGNMENT ProjectID EmployeeNumber Hours Worked 30.00 1000 1 75.00 1000 55.00 1000 10 40.00 1100 1100 45.00 6 1200 1 25.00 7 1200 2 20.00 45.00 1200 40.00 1200 35.00 10 1300 11 1300 80.00 50.00 12 1300 10 13 1400 4 15.00 14 1400 5 10.00 15 1400 6 27.50

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

The Database Experts Guide To Database 2

Authors: Bruce L. Larson

1st Edition

0070232679, 978-0070232679

More Books

Students also viewed these Databases questions