Jump to content

about sql query


abes_nitya

Recommended Posts

You use the querySelect top 5 salary from <table name> :)
No that will give you the first 5 records, if you are looking for the 5 highest salaries it would beMYSQL
SELECT * FROM emp ORDER BY sal DESC LIMIT 5

SQL Server/Access

SELECT TOP 5 * FROM emp ORDER BY sal DESC

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...