16.1k views
4 votes
The following SQL statement contains what type of subquery? SELECT b.title, b.retail, a.category, a.cataverage FROM books b, (SELECT category, AVG(retail) cataverage FROM books GROUP BY category) a WHERE b.category = a.category;

User SofDroid
by
5.7k points

2 Answers

3 votes

Answer::)

Step-by-step explanation:

User Tkerwin
by
5.7k points
6 votes

Answer:

Inline view.

Step-by-step explanation:

Inline view:-It is not a real view instead it is a sub-query or a SELECT statement in the FROM clause of the of another select statement.In the query provided we have a sub - query which is displaying category and Average of retail from the books table and this query is present in the FROM clause of other SELECT statement.

User Misha Karpenko
by
5.2k points