Using one plan per transaction
This approach was recommended prior to DB2 Version 3 because accounting at the individual package level was not possible, which forced accounting to be done by plan name. However, current releases of DB2 provide accounting at the package level, which allows for plans to be made up of a large number of packages while still providing the required accounting granularity.
About this task
The steps in using this approach are:
- Bind the DBRMs for groups of transactions or all transactions into packages. The collections to be used could be based on the transactions being converted, such as TRAN1, or on the application. The latter approach is preferable because creating and maintaining collections on a transaction basis requires greater administrative effort, particularly if there are many common routines.
- Bind a new plan for each transaction with a package list referring
to a single wildcard package list entry that would depend on the
approach
taken. Use
TRAN1.*
if the collections were based
on transactions or
COLLAPP1.*
if a single collection
was set up for all transactions:
orBIND PLAN (TRAN1) .... PKLIST (TRAN1.*) ...BIND PLAN (TRAN1) .... PKLIST (COLLAPP1.*) ... - Modify the DB2ENTRY definitions to replace the dynamic plan exit with the plan names associated with the transactions.