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...

i have column like below

studentid studentname sub1 sub2 sub3
1 aaa 40 70 90
2 bbb 60 80 50
i want to execute every student highest mark in which subject
my o/p like below
studentid studentname sub3 sub2
1 aaa 90
2 bbb 80

Answer Posted / sonal

Try below :

sel studentid,studentname, greatest(sub1,sub2,sub3) max_masks
from student

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is spool space? Why do you get spool space errors?

1084


What is inner join and outer join?

1170


How can bottlenecks be identified?

1060


Explain the advantages of partitioned primary index in a query?

1074


What is the difference between teradata and oracle?

1066


Define views in teradata with syntax.

1127


What is upsert statement in teradata?

1192


Explain BYNET.

1055


What do high confidence, low confidence and no confidence mean in explain plan?

1097


How do you set the session mode parameters in bteq?

1140


What are the various etl tools in the market?

1121


How to load specific no.of records using bteq, or fastload,or multiload

1816


What are tpump utility limitations?

1176


What is basic teradata query language?

1164


What is a three-tier data warehouse?

1153