Portal | IBM Manuals | Downloads | Products | Refer | Info | Programs | JCLs | Forum Rules*| Site Map | Mainframe CD 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index
 
Register
 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index FAQ Search Memberlist Usergroups Profile Log in to check your private messages Log in
 
db2 intv ques

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2
Author Message
karthi_ind

Active User


Joined: 24 Feb 2004
Posts: 64
Location: Chennai

PostPosted: Mon Jun 14, 2004 3:13 pm    Post subject: db2 intv ques
Reply with quote

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
View user's profile Send private message
References
ksivapradeep

Active User


Joined: 30 Jul 2004
Posts: 98

PostPosted: Wed Sep 15, 2004 9:58 am    Post subject: Re: db2 intv ques
Reply with quote

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
View user's profile Send private message
harinadh

New User


Joined: 01 Sep 2004
Posts: 18

PostPosted: Thu Sep 30, 2004 12:22 pm    Post subject: hai
Reply with quote

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
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DB2 All times are GMT + 6 Hours
Page 1 of 1