SELECT flavor, SUM (ice_cream_sales) FROM sales_detail
GROUP BY flavor ORDER BY 2 DESC
If the "sales_detail" table contains ten records with
different values in the flavor column (two "vanilla,"
three "chocolate," four "strawberry," and one NULL), how
many rows are returned by the sample code above?
1. 0 rows
2. 1 row
3. 3 rows
4. 4 rows
5. 10 rows
Answer Posted / shilpa.oracle
3 Rows.
Because group functions ignore NULL values.
flavour sum(ice_cream_sales)
vanilla 10
chocolate 27
strawberry 8
| Is This Answer Correct ? | 2 Yes | 5 No |
Post New Answer View All Answers
What is offset and limit in sql?
How can triggers be used for the table auditing?
What is raid? How does it help storage of databases?
What are sql triggers used for?
What are the main features of cursor?
what is myisam? : Sql dba
What is the purpose of normalization?
Which tcp/ip port does sql server run on? How can it be changed? : Sql dba
What is execution plan in sql?
Enlist the advantages of sql.
Which are the different character-manipulation functions in sql?
what is the difference between clustered and non clustered index in sql? : Sql dba
Is primary key always clustered index?
What is latest version of sql?
What is the difference between subquery and correlated query?