Create a list of animals that are brown in colour

Assignment Help Database Management System
Reference no: EM13850926

Database - Assignment

Background

You will be working with a set of tables for a mobile. To access these tables in oracle create the following synonyms:

SQL> CREATE SYNONYM ANIMAL FOR VBRUNO.ANIMAL;

SQL> CREATE SYNONYM KEEPER FOR VBRUNO.KEEPER;

SQL> CREATE SYNONYM CAGE FOR VBRUNO.CAGE;

SQL> CREATE SYNONYM SPECIE FOR VBRUNO.SPECIE;

SQL> CREATE SYNONYM FED FOR VBRUNO.FED;

SQL> CREATE SYNONYM FOOD FOR VBRUNO.FOOD;

Assignment Exercise

You are to prepare 15 SQL query statements that will provide answers to the following 15 requests for information.

You must submit the syntax of the queries themselves, not all the output.

1. Show a list of all the "Female" animals, that are "White", and are located in a cage whose location starts with an "A", "B", or "V". Just show the name of the animal.

2. Create a list of animals that are "Brown" in colour and less than 2 years old. Show the animal name and species name.

3. Create a view that lists all the animals that eat "straw". Show the animal no, animal name and scientific name.

4. Show the detail for cage number 147, also show the name of the animals in this cage, along with the keeper that looks after the cage, and the keeper that looks after each animal in the Include the species name for each animal in cage.

5. List all keepers from a suburb that has "WEST" in the name, who look after White animals from the snakes species. Show the keeper's full name and the animal name.

6. List all keepers that earn more than $37,000 a year at the zoo. Show the keepers name, the total salary for a year (assume 38hrs week) and the number of years they have worked at the zoo.

7. List all the cages whose size is "S"mall. Show the cage details and the name of the keeper who cleans it.

8. List all the cages that do not have any animals in them. Show all the cage details.

9. List for each MONTH of the year, how many animals are having their birthday.

10. List each of the keepers who are both vets and cleaners (‘A'). Show the keeper's name, age, how long they have worked at the zoo and their supervisor's name.

11. Create a list of each food bought by the zoo and a sum of the total quantity of each food used per day.

12. Show all the cages with six animals or more. Show the cageno, cage size, cage cost and cage location along with the keepers full name who cleans the cage.

13. For each keeper, show the number of cages cleaned by the keeper and the total cost of the cages cleaned for each keeper. Make sure you show the keeper's name. Show the highest total cost first and the lowest last on the list.

14. Need to show all the details related to a particular cage, just like in question 12, except that it must be the cage(s) that has the MOST animals in it only.

15. Create your own query. It must include a nested query. Submit the following:

a) question your query is answering

b) the SQL query

2176_Table description for the zoo database.png

Reference no: EM13850926

Questions Cloud

Write a one-page paper describing each milestone : Identify at least eight milestones for this project. Write a one-page paper describing each milestone using the SMART criteria. Discuss how determining these milestones might require new activities or tasks to the WBS and Gantt chart. Remember tha..
Compute the sst sse and ssr : compute the SST, SSE, and SSR
Create a query that updates any active employees : Create a query that updates any active employees that have 0 or null for his/her budgeted_hours_per_pay and change it to 1.23. Write a query that prints out which employees were affected.
Test the research hypothesis at the .01 level : test the research hypothesis at the .01 level
Create a list of animals that are brown in colour : Create a list of animals that are "Brown" in colour and less than 2 years old. Show the animal name and species name. Create a view that lists all the animals that eat "straw". Show the animal no, animal name and scientific name.
Calculate the standard deviation of conductance : Calculate the standard deviation of conductance
Perform a heuristic evaluation to critically evaluate : perform a heuristic evaluation to critically evaluate the selected application.
Show that it is impossible for given sequence to exist : Suppose that B1, B2,......... ω ∈ Ω is a sequence of independent events such that for all i, P[Bi] = 1/2. Show that for any n ≥ 1 and for any ω ∈ Ω, we haveP[{ω}] ≤ 1/2n
Who are the stakeholders in this situation : In the article, who are the stakeholders in this situation? What ethical issues are involved? If it is normal business practice to bribe government official in a country that you are dealing with but not in your own country, do you believe it is et..

Reviews

Write a Review

Database Management System Questions & Answers

  Knowledge and data warehousing

Design a dimensional model for analysing Purchases for Adventure Works Cycles and implement it as cubes using SQL Server Analysis Services. The AdventureWorks OLTP sample database is the data source for you BI analysis.

  Design a database schema

Design a Database schema

  Entity-relationship diagram

Create an entity-relationship diagram and design accompanying table layout using sound relational modeling practices and concepts.

  Implement a database of courses and students for a school

Implement a database of courses and students for a school.

  Prepare the e-r diagram for the movie database

Energy in the home, personal energy use and home energy efficiency and Efficient use of ‘waste' heat and renewable heat sources

  Design relation schemas for the entire database

Design relation schemas for the entire database.

  Prepare the relational schema for database

Prepare the relational schema for database

  Data modeling and normalization

Data Modeling and Normalization

  Use cases perform a requirements analysis for the case study

Use Cases Perform a requirements analysis for the Case Study

  Knowledge and data warehousing

Knowledge and Data Warehousing

  Stack and queue data structure

Identify and explain the differences between a stack and a queue data structure

  Practice on topic of normalization

Practice on topic of Normalization

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