I have a table which has thousand of records i want to
fetch only record num 100 to record num 200. Write a query
that satisfies this criteria.(Cant use any keys)
Anyone please reply ASAP!

Answer Posted / saeed

db2 "SELECT EmpNo FROM (SELECT EmpNo, dense_rank() over
(order by EmpNo) RNo FROM office) xyz WHERE RNo >= 100 AND
RNo<=200 "

Is This Answer Correct ?    0 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to retrieve rows from a db2 table in embedded sql?

735


What is role in db2?

624


What is copy pending status in db2?

642


What is cursor stability in db2?

816


What are the benefits of using the db2 database?

666






Mention a credible reason why select* is never given preference in an sql program that has been embedded.

727


How do you simulate the explain of an embedded sql statement in spufi/qmf?

641


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 .....

1906


How to get the ddl of a table in db2?

685


Is the primary key a clustered index?

619


How would you find out the total number of rows in a db2 table?

583


What is syscat in db2?

584


What is the difference between plan and package in db2?

583


Mention the length of physical storage of the given data types of db2 – date, timestamp, time

591


Explain correlated sub-queries.

591