Create the tables department employee computer and vehicle

Assignment Help PL-SQL Programming
Reference no: EM131207647

Use MySQL Workbench for these questions. Do NOT use Lucidchart. MySQL Workbench has more capability than Lucidchart, as it allows creation of DDL SQL from the model. Turn in 1 Workbench file , 1 document with the forward-engineered sql statements, and a Word document with your inserted data.

This problem mimics the one from the previous assignment. Model it in Workbench, then forward-engineer the database script and import into your database. If the import fails, fix it in the model, then try again.

A. Create the tables DEPARTMENT, EMPLOYEE, COMPUTER, and VEHICLE. Add the primary key field(s) and at least 2 non-key fields to each table that are relevant to that table (ie. PhoneNumber would be valid for EMPLOYEE). Use your model from the previous assignment to create the tables in Workbench.

B. Draw the relationships between the tables. Assume that a DEPARTMENT does not need to have an EMPLOYEE, but that every EMPLOYEE is assigned to a DEPARTMENT. The employee is assigned a laptop (COMPUTER) for his/her use, and it is not to be shared with other employees. The employee checks out a VEHICLE, but is not guaranteed a specific vehicle. So on different days, the employee may be driving a different vehicle.

C. Use the inserts tab under the table to add relevant data to the tables. Note: The inserts tool does NOT validate your data. For instance, if a field is set up as a numeric field, and you enter a letter, you will not receive an error until you actually run the script to insert the data in the table. Make sure the business rules are met by inserting specific data: A: Try to assign 2 employees to the same department. B: Try to assign 2 computers to 1 user, and 2 users to 1 computer. (This should fail in step 1e below. Fix the model and/or the data before submitting). C: Try to assign an employee to 2 vehicles, and a vehicle to 2 employees.

D. Forward-Engineer the database, and make sure to check "Generate INSERT Statements for Tables." In the "Review the SQL Script to be Executed" screen, click "Save To File..." Choose a name like "A11.sql".

E. If the script fails, fix the model and/or the insert data, forward-engineer the script again, then re-run the script. Do this until you don't have any errors.

F. Once the script executes successfully, go back to the model and copy the data from each table into a Word document. The data should paste in as a table. To copy data from Workbench, open the Inserts tab from C above. Select all data by clicking on the area above and to the left of the table (see example right). Type Ctrl-C to copy the data. Paste it into a Word document. Continue with all of the tables. Save the document to a file like "A11.docx".

Reference no: EM131207647

Questions Cloud

What is the target cost for the new game : If L"Oso desires a 60% markup on production costs, what is the target cost for the new game? -  Justin believes it will cost $24 per unit to produce the new game. What actions should he take next?
Find its clean and dirty values at the end of each quarter : A $1,000 seven-year 6% bond with semiannual coupons is redeemable for $1,065. It was originally purchased at issue for $970. It is sold after 45 months for $995. Find the accrued interest by the practical method and again by the theoretical method..
What impact does this drug use or abuse have on the state : Explained at least two ways that this substance is problematic for society. Evaluated at least two ways this drug and its use have affected the state of families in the U.S.
Functions and role of law in business and society : Write a 700- to 1,050-word paper in which you explain the functions and role of law in business and society.
Create the tables department employee computer and vehicle : Create the tables DEPARTMENT, EMPLOYEE, COMPUTER, and VEHICLE. Add the primary key field(s) and at least 2 non-key fields to each table that are relevant to that table (ie. PhoneNumber would be valid for EMPLOYEE).
Calculate two ratios first using aspe and then using ifrss : Calculate the two ratios first using ASPE and then using IFRSs. - Prepare a schedule showing any adjustments to the numerator and denominator for these ratios. Ignore income taxes.
Calculate total restaurant sales and sales of each product : Calculate the total restaurant sales and the sales of each product line that would be necessary to achieve the desired target net income
How you personally feel about treating such an individual : Pretend that you are the psychologist who is assigned to treat this individual. Describe in detail some of the instruments/tools that you would use to assess risk and diagnose this individual.
Describe the most fun aspect of the given assignment : Describe most fun aspect of the assignment. Describe the most challenging aspect of the assignment. Describe the most difficult aspect of the assignment to understand. Provide any suggestions for improving the assignment in the future.

Reviews

Write a Review

PL-SQL Programming Questions & Answers

  Create a database model

Create a database model and Submit the table creation statements for the Database Model.

  Write pl-sql procedures and functions

Write PL/SQL procedures and functions to populate and query that database

  Sql questions

Write a query to display using the employees table the EMPLOYEE_ID, FIRST_NAME, LAST_NAME and HIRE_DATE of every employee who was hired after to 1 January, 1995.

  Run the lab_03_01.sql script

Run the lab_03_01.sql script in the attached file to create the SAL_HISTORY table. Display the structure of the SAL_HISTORY table.

  Write sql queries

Write a query to display the last name, department number, and salary of any employee whose department number and salary both match the department number and salary of any employee who earns a commission.

  Explaining sql insert statement to insert new row in cds

Write down a SQL insert statement to insert new row in "CDS" table.

  Write down name of actors in ascending order

Write down actors (or actress, your choice, but not both) who have won at least two (2) Academy Awards for best actor/actress. Provide the actor name, movie title & year. Order the result by actor name."

  What is an sql injection attack

What is an SQL injection attack? Explain how it works, and what precautions must be taken to prevent SQL injection attacks.What are two advantages of encrypting data stored in the database?

  Determine resonant frequency in series rlc resonant circuit

Given the series RLC resonant circuit in the figure, operating at variable frequency, determine: The resonant frequency ω o ,  The circuit’s quality factor Q , The cut-off frequencies, f 1  & f 2  and the bandwidth BW

  Query that uses cube operator to return lineitemsum

Write summary query which uses CUBE operator to return LineItemSum (which is the sum of InvoiceLineItemAmount) group by Account(an alias for AccountDesciption).

  Query to show customers were missing for existing orders

As DBA, your manager called a meeting and asked why there are so many orders for customers that don't exist in the customer table. Write query which would shows which customers were missing for existing orders. Use a join or a subquery.

  Sql query into a relational algebra statement

Turn this SQL query into a relational algebra statement? SELECT Request.reqfor, Ordering.invamt, Ordering.invnbr, Ordering.invdat

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd