DB2 Questions   «Prev  Next»

DB2 Package and Plan Questions

  1. What is the difference between a package and a plan?
    How does one bind 2 versions of a CICS transaction with the same module name in two different CICS regions that share the same DB2 subsystem?

    Answer: Package and plan are usually used synonomously, as in this site. Both contain optimized code for SQL statements - a package for a single program, module or subroutine contained in the datebase request module (DBRM) library.
    A plan may contain multiple packages and pointers to packages. The one CICS module would then exist in a package that could be referenced in two different plans.

  2. What is an asychronous write?

    Answer: It is a write to disk that may occur before or long after a commit.
    The write is controlled by the buffer manager.

  3. Question : What is a lock?

    Answer: A lock is the mechanism that controls access to data pages and tablespaces.

  4. What is meant by isolation level?

    Answer: This is a key concept for any relational database.  Isolation level is the manner in which locks are applied and released during a transaction.   For DB@ a repeatable read holds all locks untile the transaction completes or a syncpoint is issued.  For transactions using 'cursor stability' the page lock releases are issued as the cursor 'moves', i.e. as the transaction releases addressability to the records.

  5. What are leaf pages?

    Answer: They are the opposite of root pages.
    Leaf pages are the lowest level index pages - the pages that contain index entries and information to the corresponding table rows.

  6. What is a precompiler?

    Answer: It is a DB2 facility for static SQL statements - it replaces these statements with calls to the DB2 language interface module.

  7. What is a root page?

    Answer: The opposite of a leaf page; it is the highest level index page.
    An index can contain only the one root page; all other index pages are associated to the root.

  8. What is a thread?

    Answer: A thread is the connection between DB2 and some other subsystem, such as CICS or IMS/DC.