Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Update the name of the Branches table that you created in the previous lab to say Department. Use an ALTER statement to RENAME the Branches

Update the name of the Branches table that you created in the previous lab to say "Department".
Use an ALTER statement to RENAME the Branches table to "Department".
Capture these outputs in a screenshot to validate that you successfully completed this step.
Insert fields to the Department table so that joins can be performed on tables.
INSERT INTO Department VALUES
(1, 'Accounting'),
(2, 'Human Resources'),
(3, 'Information Systems'),
(4, 'Marketing');
Write a SELECT statement for this table to prove this step and validate that it ran correctly with a screenshot.
Perform joins between the Department and Employee tables and show results for how many employees work in each of the four departments. This action will only provide information on the records that are already there.
Department 1= Accounting
Command: SELECT First_Name, Last_Name, Department.Department_Name FROM Employee INNER JOIN Department
ON
Employee.Department_ID = Department.Department_ID WHERE Employee.Department_ID =1;
Using SELECT statements similar to that above, perform joins to produce results for the following tables:
Department 2= Human Resources
Department 3= Information Systems
Department 4= Marketing
Capture the results of these joins and validate your work by providing a screenshot. You should have the same number of records as you do employees.
Populate the Employee table with information for 10 new employees.
Give the employees unique names and include attributes for all necessary fields. Note: Reference attributes from the lab in Module Two. Department ID values must be between 1 and 4.
Perform a join across the Employee and Department tables for each of the four departments. New and existing records should be displayed in the result.
PLEASE HELP WITH POPULATING THE EMPLOYEE TABLE GIVE EXAMPLES IT ISNT WORKING

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

Database Design Application Development And Administration

Authors: Mannino Michael

5th Edition

0983332401, 978-0983332404

More Books

Students also viewed these Databases questions

Question

3. Existing organizations and programs constrain behavior.

Answered: 1 week ago