Which two SQL statements would executes successfully?

See the Exhibit and examine the structure and data in the INVOICE table: Exhibit: Which
two SQL statements would executes successfully? (Choose two.)

See the Exhibit and examine the structure and data in the INVOICE table: Exhibit: Which
two SQL statements would executes successfully? (Choose two.)

A.
SELECT MAX(inv_date),MIN(cust_id) FROM invoice;

B.
SELECT MAX(AVG(SYSDATE – inv_date)) FROM invoice;

C.
SELECT (AVG(inv_date) FROM invoice;

D.
SELECT AVG(inv_date – SYSDATE),AVG(inv)amt) FROM invoice;

Explanation:



Leave a Reply 4

Your email address will not be published. Required fields are marked *


Noble

Noble

d or c , i m confused !!!!

alexy

alexy

select max(avg(sysdate – inv_date)) from invoice
Error at Command Line : 23 Column : 12
Error report –
SQL Error: ORA-00978: nested group function without GROUP BY
00978. 00000 – “nested group function without GROUP BY”
*Cause:
*Action:

shweta

shweta

please send me the explanation.

shreyas

shreyas

i think we can take average of only number data type and not date
ORA-00932: inconsistent datatypes: expected NUMBER got DATE