Suppose you create a students record with 5 marks, total and average.How to filter the top 3 students which are getting high average.

Showing Answers 1 - 9 of 9 Answers

hey, here you have to use nested sub queries and also compare the same table by using 2 times. try this command. hopefully it will work

select  a.stuname, a.stumarks, a.total, a.average from student a
where 3=(select count(distinct(b.average))
from student b
where a.average<b.average

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions