Processing requests for access to migrated rows
Once DB2 Manager initialization has been completed, batch, TSO, CICS or IMS programs will be able to access migrated rows using standard SQL processing, without modification.
DB2 Manager implements support for access to migrated rows which is made via SQL SELECT, UPDATE and DELETE commands. Note that any rows created in a table via an SQL INSERT command will be stored in DB2. It is not possible to directly store a row in an Archive Manager database – a row must be migrated from a DB2 table to an Archive Manager database, using the DB2 Manager table migration utility.
SQL SELECT processing
Any reference to a migrated row generated via an SQL SELECT command will cause the DB2 Manager SQL intercept processor to pass a request to the DB2 Manager control region. This request will be processed by a scheduler task, which will perform some initial validation.
If the object containing the required row is
If the object containing the required row is
1.A busy task which is processing the tape volume containing the object to be retrieved, and whose request queue is not greater than the maximum specified in the MAXQLEN initialization parameter.
2.A waiting task which has no tape mounted.
3.A waiting task which currently has a tape mounted.
| If there is no tape reader task satisfying any of the above conditions, the |
| request will be rejected with a “resource unavailable” condition, unless a non- |
| zero value is specified for the TAPEWAIT initialization parameter. In these |
| circumstances, the request is queued internally and retried until it has been |
| successfully assigned to a tape reader task, or until the time interval specified |
| in the TAPEWAIT parameter has been exceeded, in which case it will be |
| rejected with a “resource unavailable” condition. Refer to page 41 for a |
| description of the TAPEWAIT parameter. |
| When a request has been passed to a tape or disk reader task, the task will |
| locate the object containing the migrated row and extract the logical record |
| containing the row. This will be passed back to the SQL intercept routine, |
| which will in turn pass the required row back to the calling application. |
| The RETAINTAPE initialization parameter may be used to retain a tape |
| volume on a drive for a specified period of time when a tape reader task has |
| processed all outstanding requests for retrieval of objects from that tape |
48 | DB2 Manager User Guide |
| StorageTek Proprietary |