Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Using the vehicle database in Appendix A (provided below) , answer in SQL statements for each of the following queries. a) Using SQL statement,

Using the vehicle database in Appendix A (provided below), answer in SQL statements for each of the following queries.  

a) Using SQL statement, show the name of employees who are in business or administration.  

b) Find the ergo numbers of cars that were taken by employee number 118.

c) Find the cars that were used by Employees in the Information Tech Department. 

d) Find the number of cars used by employees whose number is above 120, excluding those employees who are part of the Information tech department. 

e) Find the name and department of the employees, who have taken a Mazda and Ford car between 11/08/2011 and 11/09/2011.

f) Find the employee names who used the most cars.  

g) Find the employee/s who returned a vehicle on 15/11/2011.  

h) Find the employee/s who taken a vehicle on 02/09/2011 and 12/09/2011. 

Vehicle Beg No Make BRG446 Ford VRG655 Bmw NMT667 Madza CCT899 Toyota FGR122 Mitsubishi Employee Table 

Vehicle Beg No Make BRG446 Ford VRG655 Bmw NMT667 Madza CCT899 Toyota FGR122 Mitsubishi Employee Table Employee No 118 123 156 166 120 134 Employee v eh A12 Employee Vehicle Table A13 A14 A15 A16 A17 A18 A19 A20 FirstName Riley Bryn Anna Justin Sarah Tammy Model Meteor Coupe Delivery Van HiLuxe Magna Reg No BRG446 NMT667 CCT899 FGR122 BRG446 NMT667 NMT667 FGR122 NMT667 Year 2009 2008 2010 2009 2007 0 LastName Griffin Underwood Thanh Brownworth McDonald Hubber Employee N 118 1/09/2011 156 2/09/2011 166 2/09/2011 134 3/09/2011 118 4/09/2011 Colour White Department Business Information Tech Administration Date Taken Blue Green Red Purple Business Services Manager Date Returned 3/09/2011 3/09/2011 4/09/2011 5/09/2011 10/09/2011 166 5/09/2011 10/09/2011 134 11/09/2011 15/09/2011 166 12/09/2011 15/11/2011 118 14/11/2011 15/11/2011

Step by Step Solution

3.40 Rating (159 Votes )

There are 3 Steps involved in it

Step: 1

Question a Selecting the first and last name of employees who are in business or administration SELECT FirstName LastName FROM Employee WHERE Departme... 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

Income Tax Fundamentals 2013

Authors: Gerald E. Whittenburg, Martha Altus Buller, Steven L Gill

31st Edition

1111972516, 978-1285586618, 1285586611, 978-1285613109, 978-1111972516

More Books

Students also viewed these Databases questions

Question

12. What is a marketing information system (MIS)?

Answered: 1 week ago

Question

Name three applications for feedback control systems.

Answered: 1 week ago

Question

10. What is meant by a feed rate?

Answered: 1 week ago