Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

24. Display the order number for all orders whose average
item cost is greater than the overall average item cost
across all orders.

Answer Posted / sarath

Small correction to the above answer. Its not MAX, but AVG
Sorry for the mistake

select ORDER_NO,AVG(ITEM_COST) from <TN>
Group by ORDER_NO
having AVG(ITEM_COST) > (Select AVG(AVG(ITEM_COST)) from
<TN> Group by ORDER_NO)

This is to display the Order no whose AVG is > Resultant AVG of All Order's AVG(ITEM _Cost)

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain the difference between replace() and translate() functions in oracle?

976


What does sharding mean?

950


How to empty your oracle recycle bin?

983


How do I escape a reserved word in oracle?

1132


How to select some rows from a table in oracle?

1009


What is the effect of setting the value "all_rows" for optimizer_goal parameter of the alter session command? What are the factors that affect optimizer in choosing an optimization approach?

974


How to define and use table alias names in oracle?

885


What do you mean by a deadlock?

1011


What is the usage of control file in oracle?

1028


Give the different types of rollback segments.

982


IS it possible to built the oracle database without setting the kernal parameters?

2272


How to write text literals in oracle?

1021


How many types of synonyms in Oracle?

1069


Is it possible to center an object horizontally in a repeating frame that has a variable horizontal size ?

2302


Can u please explain me the Discussion on Except ,using cast like type cast. Question in the context of difference between two tables

2000