View previous topic :: View next topic
|
Author |
Message |
Balasubramanian
New User
Joined: 23 Apr 2005 Posts: 13 Location: Bangalore
|
|
|
|
Hi all,
I have a question in using Packages.
When we use the concept of 'PLAN' in program process, we will be doing like COMPILE+BIND PLAN+RUN PLAN.
If we use PACKAGE instead of PLAN, how the execution flow should be done and what other components will get involved during the process such as COLLECTION etc.
Thanks in advance
Balasubramanian S |
|
Back to top |
|
|
King
New User
Joined: 10 May 2005 Posts: 1
|
|
|
|
When you use the concept of 'PACKAGE' in program process, we will be doing COMPILE+BIND PACKAGE+RUN PLAN.
There is no need to do any BIND PLAN.
The Plan will have multiple Packages for "same" program in the same PLAN, if Package Version feature is supported. Otherwise in BIND Package there is a parameter "ACTION (REPLACE)" will replace existing package with new package created. So when you run the program using PLAN proper package will be selected using time stamp matching procedure.
I hope I am correct, I answered your question. |
|
Back to top |
|
|
Balasubramanian
New User
Joined: 23 Apr 2005 Posts: 13 Location: Bangalore
|
|
|
|
Then which name will be reffered for PLAN while RUN.
And Where the COLLECTIONS parameter shall be used.
Expecting your reply
Thanks in advance
Balasubramanian S
King wrote: |
When you use the concept of 'PACKAGE' in program process, we will be doing COMPILE+BIND PACKAGE+RUN PLAN.
There is no need to do any BIND PLAN.
The Plan will have multiple Packages for "same" program in the same PLAN, if Package Version feature is supported. Otherwise in BIND Package there is a parameter "ACTION (REPLACE)" will replace existing package with new package created. So when you run the program using PLAN proper package will be selected using time stamp matching procedure.
I hope I am correct, I answered your question. |
|
|
Back to top |
|
|
pnk519
New User
Joined: 13 Nov 2003 Posts: 5
|
|
|
|
Hi,
U cannot execute a program without PLAN...
suppose if we R using PACKAGE then we will be doing
Precompile+ BIND PACKAGE + BIND PLAN + RUN
your packages will be stored in DB2 Directory, in the form of collections, i.e. collection is a set of packages.
we will give the collection id at the time of BIND PACKAGE...
PACKAGE contains optimized access path to your data...
PACKAGE is not executable. it can be only executed via a PLAN
PLAN or APPLICATION PLAN contains set of pointers to PACKAGES
and provides collections where the PACKAGE should be searched at
execution time
We will give
BIND PLAN(plan-name) PKLIST(col1.*,col2.*)
then at execution time package will be searched in these columns (by run time supervisor) if PACKAGE is not found we will get SQLCODE = -805
i.e program name not found in PLAN.
and at last remember that there will be one DBRM per program
and one PACKAGE per DBRM, and name of DBRM, Program name , package-id will be same
---Naren |
|
Back to top |
|
|
|