can any one tell me how to write the query to find out first 6 highest salary from table
note: not 6 th highest salary ....
sivak
-7
Junior Poster
Recommended Answers
Jump to Postactually it needs to be descending or else you will get bottom to top
select top 6 * from table_name order by salary desc
Jump to Posthe said the 6 highest salaries, if you do an asc sort, you will get the 6 lowest salaries, not highest
All 5 Replies
james_zheng
0
Newbie Poster
dickersonka
104
Veteran Poster
james_zheng
0
Newbie Poster
dickersonka
104
Veteran Poster
james_zheng
0
Newbie Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.