hi, i have 3 cols in my db
col 1 ( unique identifier )
col2 ( varchar )
col 3 ( integer )

how can i retrive the 3 greatest values from the database on the basis of col 3..

Recommended Answers

All 2 Replies

select top 3 *
from tableName
order by col3 desc
commented: thanx for your reply. +2
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.