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


Please Help Members By Posting Answers For Below Questions

What are sql ddl commands?

557


what are the properties and different types of sub-queries? : Sql dba

514


How do I start sql profiler?

563


What is normalization sql?

521


What is a null value?

665






Why function is used in sql?

528


What do you mean by stored procedures?

560


Are there any features that are decommissioned in 11g that are not present in 11g?

1606


What is rollback?

595


How to generate a salary slip like jan 1000 1000 feb 1000 2000 ... dec 1000 12000

1650


What is equi join in sql?

619


Mention what are the benefits of pl/sql packages?

542


Hi how to import oracle sequence in Informatica? Please write stored procedure code that will import oracle sequence in Informatica SP transformation as per below scenario Oracle table product list Pro_id, pro_name 101, LED Lights. 102, 20watt CFL Lights. 103, 30 watt CFL lights Now a new flat file with new product list needs to be added to oracle table product list with oracle sequence. flat file product Prono,pro_name, 1, 20 watt tube light 2, 30 watt tube light & target should be like 101, LED Lights. 102, 20watt CFL Lights. 103, 30 watt CFL lights. 104, 20 watt tube light 105, 30 watt tube light thks reg suvarna joshi suvarnaatsuvarna@rediffmail.com

2076


Can you selectively load only those records that you need? : aql loader

618


What is a scalar value in sql?

594