View previous topic :: View next topic
|
Author |
Message |
karthi_ind
Active User
Joined: 24 Feb 2004 Posts: 131 Location: Chennai
|
|
|
|
hi toall
1) how to retrieve first n records in a table
for example first 5 records
in oracle we hve a option called rowid
but in db2 i hve no idea. how can we retrieve??
2) how can we retrieve rows frm centre i.e frm 9th rec to 14th rec
( is it possible in db2)
3) can anyone explain the db2 precompiler process?
(such as bind,package,collection,dbrm,runtime supervisor,
buffer mgr)
anbudan
karthi G. |
|
Back to top |
|
|
ksivapradeep
New User
Joined: 30 Jul 2004 Posts: 95
|
|
|
|
hi karthi,
1) ans: we can retrive the first n recors by FETCH FIRST option.
query: select * from table-name FETCH FIRST n ROWS ONLY
regards,
siva pradeep |
|
Back to top |
|
|
harinadh
New User
Joined: 01 Sep 2004 Posts: 18
|
|
|
|
After Precompilation the output is new source cobol list and DBRM.
DBRM is the collection of SQL statements.
Plan is the compiled form of SQL statements. It contains the optimum path to execute that SQL statements.
Plan is two types one is BIND PLAN and another one is BIND PACKAGE.
FOR BIND PLAN THE INPUT IS MORE THAN ONE DBRM.I.E. PACKAGES...
FOR PACKAGE THE INPUT IS ONLY ONE DBRM.
PLAN IS THE COMPILE FORM OF MORE THAN ONE DBRM. IT MAY BE ONE. |
|
Back to top |
|
|
|