Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Finding Top three students,

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2004-07-06 : 11:56:05
arul writes "i want to find the top three students who get the top three highest marks.

ROLL NO
NAME
MARK
05 A 55
20 B 50
15 C 75
10 D 95"

drymchaser
Aged Yak Warrior

552 Posts

Posted - 2004-07-06 : 12:00:50
select top 3 [roll no], [name], mark
from table
order by mark desc

will work for your sample data
Go to Top of Page
   

- Advertisement -