Can you help me to do it in mysql workbench, XMAPP 4. Exercise 6.4.7: Write the following
Fantastic news! We've Found the answer you've been seeking!
Question:
Can you help me to do it in mysql workbench, XMAPP
Transcribed Image Text:
4. Exercise 6.4.7: Write the following queries, based on the database schema ) Classes (class, type, country, numGuns, bore, displacement Ships (name, class, launched) Battles (name, date) Outcomes (ship, battle, result ) of Exercise 2.4.3. and evaluate your queries using the data of that exercise. a) Find the number of battleship classes. b) Find the average number of guns of battleship classes. c) Find the average number of guns of battleships. Note the difference between b) and c); do we weight a class by the number of ships of that class or not? d) Find for each class the year in which the rst ship of that class was launched. e) Find for each class the number of ships of that class sunk in battle. 4. Exercise 6.4.7: Write the following queries, based on the database schema ) Classes (class, type, country, numGuns, bore, displacement Ships (name, class, launched) Battles (name, date) Outcomes (ship, battle, result ) of Exercise 2.4.3. and evaluate your queries using the data of that exercise. a) Find the number of battleship classes. b) Find the average number of guns of battleship classes. c) Find the average number of guns of battleships. Note the difference between b) and c); do we weight a class by the number of ships of that class or not? d) Find for each class the year in which the rst ship of that class was launched. e) Find for each class the number of ships of that class sunk in battle.
Expert Answer:
Answer rating: 100% (QA)
a Find the number of battleship classes SELECT COUNTDISTINCT class AS numclasses FROM Classe... View the full answer
Related Book For
Posted Date:
Students also viewed these databases questions
-
Let A, B be sets. Define: (a) the Cartesian product (A B) (b) the set of relations R between A and B (c) the identity relation A on the set A [3 marks] Suppose S, T are relations between A and B, and...
-
The following additional information is available for the Dr. Ivan and Irene Incisor family from Chapters 1-5. Ivan's grandfather died and left a portfolio of municipal bonds. In 2012, they pay Ivan...
-
Please submit the SQL commands with the results. The results should be cleaned up of duplicates, and if they have a large result in the result set (more than 15 rows), please submit the first few....
-
How is it that a state, or any state, such as Oregon, can offer more provisions under FMLA (OFLA) than then the federal rule of FMLA does?
-
Section 26.9 gives two formulas for a down-and-out call. The first applies to the situation where the barrier, H, is less than or equal to the strike price, K. The second applies to the situation...
-
If the net income for the current year had been $240,000 in Exercise 3-23, what would have been the correct net income if the proper adjusting entries had been made?
-
Describe and illustrate the following four types of damages: Nominal Actual General Punitive
-
Martinez Company owns a building that appears on its prior year-end balance sheet at its original $572,000 cost less $429,000 accumulated depreciation. The building is depreciated on a straight-line...
-
a) A financial institution is a financial intermediary (FI'S) that facilitates the transfer of funds between suppliers and users of funds. Briefly explain the benefits that FI's provide to the...
-
Early in its fiscal year ending December 31, 2024, San Antonio Outfitters finalized plans to expand operations. The first stage was completed on March 28 with the purchase of a tract of land on the...
-
Highly Suspect Corporation has current liabilities of $412,000, a quick ratio of 1.50, inventory turnover of 4.10, and a current ratio of 3.20. What is the cost of goods sold for the company?
-
Martha owns a painting by Canadian artist Maud Lewis. A number of years ago she paid $10,000 to acquire the painting. Based on a recent appraisal, the painting is now worth $35,000. Inadequate...
-
14. a) Explain what is meant by the Fisher Separation Theorem (FST). Graphically demonstrate FST for the case where an individual ends up lending in financial markets. (40 marks) b) Graphically...
-
Relevant Info: Civil law covers a very broad range of subjects, including adoption, admiralty, collections, corporate, divorce, employment, environmental, intellectual property, personal injury,...
-
City Foods, is a firm that is experiencing rapid growth. The firm just paid a dividend of $5.00 yesterday. They expect to see their dividend grow at a twenty percent rate for the next two years and...
-
Instructions. Answer the following questions logically and concisely giving your basis whenever possible. When required to explain, the sentences should not be less than two sentences to obtain...
-
"Bentham seems to equate happiness with pleasure. Are there significant differences between pleasure and happiness? Do the characteristics of time, sensation or emotion differ for each? Can one be...
-
Use critical values to test the null hypothesis H0: 1 2 = 20 versus the alternative hypothesis H0: 1 2 20 by setting a equal to .10, .05, .01, and .001. How much evidence is there that the...
-
First State Bank offers a wide range of banking services, including checking accounts, certificates of deposit, loans, credit cards, and safety deposit boxes. Bank managers know that customer...
-
Larry's Lawn Service needs to purchase a new lawnmower costing $7,756 to replace an old lawnmower that cannot be repaired. The new lawnmower is expected to have a useful life of four years, with no...
-
Scott Sykes publishes a pilot training course curriculum kit that he sells to flight schools across the country. He prepared the following static budget for the year based on expected sales of 30,000...
-
What are the numbers of observations in each of the five categories that rate the respondents level of job satisfaction?
-
Which of the seven store departments had the most customer visits, and what was this number?
-
How many individuals are in each of the five different credit card categories?
Study smarter with the SolutionInn App