adspace
Please get the 4 th maximum salary from a table without
using any sql keyword (TOP,MAX are mot allowed)
Answer Posted / sumathy
Create Table 'Employee' with columns 'Emp_Name'
and 'Salary'. And, Insert some data.....
Cursor:
declare Cursor_Name cursor scroll
for select salary from Emploee order by salary desc
open Cursor_Name
fetch absolute 2 from Cursor_Name
deallocate Cursor_Name
| Is This Answer Correct ? | 2 Yes | 2 No |
Post New Answer View All Answers
what is spatial nonclustered index
How efficient you are in oracle and SQL server?
List out the different types of locks available in sql server?
What are the kinds of subquery?
explain different types of backups avaialabe in sql server? Given a particular scenario, how would you go about choosing a backup plan? : Sql server database administration
What are different types of constraints?
Can sql servers link to other servers like oracle?
What is self contained sub query?
Where can you add custom error messages to sql server?
What are the properties of the transaction?
What is the difference between upgrade and migration in sql server?
what is the difference between openrowset and openquery?
What is clustered index
Disadvantages of the indexes?
How do I find query history in sql server?