write a procedure to find top second no from a list of
numbers



write a procedure to find top second no from a list of numbers..

Answer / roshan

create or replace procedure pr_getmax(enter_number in
number,sal out number)
as
begin
select salary into sal from
(select rownum rn,salary
from
(select
a.salary
from
employees a
order by a.salary desc) )a
where
a.rn = enter_number;
end;

Is This Answer Correct ?    2 Yes 2 No

Post New Answer

More SQL PLSQL Interview Questions

How to write a procedure for displying the data in a TREE or (PARENT and CHILD ) relationship , for ex: A is the main project id, for this project B,C,D are sub tasks(sub project id's) for B the sub tasks are e,f,g and for c is h ,i ,j and for d is k,l,m now i need to display the o/p in a TREE fashion pls help me , thanks in advance surendra

2 Answers   Zensar,


What is raid? How does it help storage of databases?

0 Answers  


What is difference between table and view?

0 Answers  


What is data manipulation language?

0 Answers  


How to access the current value and next value from a sequence?

6 Answers  






how to get @@error and @@rowcount at the same time? : Sql dba

0 Answers  


What are the benefits of pl/sql packages?

0 Answers  


What is a database link?

3 Answers  


How to convert ms-excel file to oracle table?

2 Answers  


Can we use pl sql in sql server?

0 Answers  


what is global table

7 Answers   iFlex,


suppose u hav 1 book with set...page 1-100 n 101 -200 now print page from 2-100 n 102 -200... how we will do..?

6 Answers  


Categories