2. Display the item number and total cost for each order
line (total cost = no of items X item cost). Name the
calculated column TOTAL COST.
Answers were Sorted based on User's Feedback
Answer / girija.112
ANS:
SELECT ITEM_NO , NO_OF_ITEMS*INDIVIDUAL_ITEM_COST AS "TOTAL COST"
FROM ITEM_TABLE
ITEM_NO TOTAL COST
1001 30000
1002 40000
1003 72000
1004 100000
1006 40000
1007 60000
1008 80000
1009 -
1010 56000
I have assumed that ITEM_NO, NO_OF_ITEMS &
INDIVIDUAL_ITEM_COST columns are in a single table ITEM_TABLE
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / ajit
select itemnum,totalcost
from <tab name>
group by cube(itemnum, totalcost);
| Is This Answer Correct ? | 0 Yes | 0 No |
How to create a table interactively?
Explain compound trigger in oracle?
What is the cache hit ratio, what impact does it have on performance of an Oracle database and what is involved in tuning it?
How to use "while" statements in oracle?
What do you mean by a database transaction & what all tcl statements are available in oracle?
How can we create the complete backup of data in the oracle.
0 Answers IPEC, Satyam, SunTec,
What is the use of file param in imp command?
what is the use of triggers in Java program? I mean where do we use triggers in Java programming?
How are Indexes Update ?
How do I learn what codesets are available in oracle?
How to find the duplicate rows count from employees table in oracle?
how may join possible between (requisition with purchase order)