i have table agdet i want first 5 maximum commission which
query will you write for this thanks in advance

Answers were Sorted based on User's Feedback



i have table agdet i want first 5 maximum commission which query will you write for this thanks in..

Answer / yuvaevergreen

exec sql
select commission from agdet order by commission desc
fetch first 5 rows only
end-exec;

Is This Answer Correct ?    10 Yes 0 No

i have table agdet i want first 5 maximum commission which query will you write for this thanks in..

Answer / girish

select * from agdet a where 5 >= (select commission from
agdet a , agdet b where b.commission > = a. commission)with
ur;

Is This Answer Correct ?    0 Yes 3 No

i have table agdet i want first 5 maximum commission which query will you write for this thanks in..

Answer / thiru

select * from agdet order by commission fetch first 5 rows
only for read only with ur

Is This Answer Correct ?    3 Yes 7 No

Post New Answer

More DB2 Interview Questions

Describe major components of db2?

0 Answers  


In my table having 100 Rec. How can I delete the 7th row?? (we don't know what is data inside the table)

9 Answers   IBM,


How do you run JCL in cobol program

1 Answers   IBM, Syntel,


Can a primary key have null values? If we try to insert a null value in a primary key column, will it work or give an error code?

6 Answers  


What is a DB2 catalog?

2 Answers  






How does cobol compile db2 program?

0 Answers  


how to resolve -805 . how to see dbrm and package not found

2 Answers   IBM,


How does DB2 use multiple table indexes?

1 Answers  


Explain about rct.

0 Answers  


How many sub queries can you combine together ?

4 Answers   IBM,


How can you display the current date & current time ?

7 Answers   Cap Gemini,


What is cursor?

2 Answers  


Categories