Question: Topic: SQL / Database Management Given the following schema, rank tree species from widest to thinnest based on average girth at age 10. Tree( id

Topic: SQL / Database Management

Given the following schema, rank tree species from widest to thinnest based on average girth at age 10.

Tree(id: string, species: string, height: float, girth: float, age: int)

Group of answer choices

1. SELECT species, AVG(girth) FROM Tree WHERE age = 10 GROUP BY species ORDER BY AVG(girth) DESC

2. SELECT species, AVG(girth) FROM Tree WHERE age = 10 GROUP BY species ORDER BY girth DESC

3. SELECT species, AVG(girth) FROM Tree WHERE age = 10 ORDER BY species, AVG(girth) DESC

4. SELECT species, AVG(girth) FROM Tree WHERE age = 10 GROUP BY species ORDER BY AVG(girth)

5. SELECT species, age = 10, AVG(girth) FROM Tree GROUP BY species ORDER BY girth DESC

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!