how to fetch first 100 rows in db2

Answers were Sorted based on User's Feedback



how to fetch first 100 rows in db2..

Answer / sesha

SELECT * FROM TABLE
FETCH FIRST 100 ROWS
ONLY

Is This Answer Correct ?    34 Yes 2 No

how to fetch first 100 rows in db2..

Answer / jagan

select top 100 from tableName;

Is This Answer Correct ?    1 Yes 12 No

Post New Answer

More DB2 Interview Questions

I need to view the number of tables existing under one particular Owner. Is it possible? If so, pl give the SQL query for this?

3 Answers  


I have two tables A and B. Both tables are connected with SSN number as foreign key. I want to retrieve a column data from B table. How will you write a query?

3 Answers   CTS,


Can a array declared with an index be displayed(readable format) in spool?

4 Answers   Syntel, UST,


Why PS file called Physical seqential file?How to sore data in sequential file and ESDS file? What is the use of DBRM,PLAN,package and Collection.

1 Answers  


in a table consist of 1000 records among that i was updated 145 record how could i know that ..list of recently updated record's and where could i see those updated record's....pls help me out....

4 Answers   Infosys,






1. what if null values retrived from database and no null indicator mentioned in query. What is sql code.

1 Answers   Cap Gemini,


What are packages in db2?

0 Answers  


How do you prepare a COBOL + DB2 program from coading till execution ?

1 Answers   Amdocs, Xansa,


Hi Everyone... Under the Logical files, when am working on multiple rec format logical file, I have joined two pf's using the multiple record format logical file concept, but when i run queried the LF only the first mentioned pf records are reflecting and I am not able to see any of the field records specified under the second pf. Kindly let me know whats the reason behind this. Below is the str of LF., R rec PFILE(LOGICAA) CUSTNO CUSTNAME BILL K CUSTNO R rec1 PFILE(LOGICAA1) CUSTNO ADD K CUSTNO .....

0 Answers  


What is the maximum number of tables that can be stored on a Partitioned Table Space ?

1 Answers   IBM,


Can we delete records from view?

0 Answers  


What is null value in db2?

0 Answers  


Categories