HP 3000 Manuals

Database Close [ HP Transact Reference Manual ] MPE/iX 5.0 Documentation


HP Transact Reference Manual

Database Close 

A database can be closed in Transact by:

   *   Using the CLOSE verb

   *   Calling DBCLOSE via the PROC statement

   *   Ending the program

You can use the CLOSE verb to perform a database (DBCLOSE mode 1) or data
set (DBCLOSE mode 2) close.  Rewinding a data set (DBCLOSE mode 3) is not
done by the CLOSE verb.  However, rewinding the data set occurs
automatically when serially (or reverse-serially) reading data sets for
the FIND, GET, and OUTPUT statements.  If the CLOSE verb is used in the
middle of a dynamic transaction, a TurboIMAGE error message is issued and
the transaction is aborted.

You can use the PROC statement to call DBCLOSE at anytime in a Transact
program.  A call to DBCLOSE mode 3 (rewind) is allowed within a dynamic
transaction.  However, if a call is made to DBCLOSE mode 1 or mode 2, a
TurboIMAGE error message is issued and the dynamic transaction is
aborted.

A database is usually not closed until the program ends, at which time
Transact automatically closes the database.  No transactions should be in
process at this time.  However, if a transaction is in process, the
transaction will be aborted and an error message will be issued.



MPE/iX 5.0 Documentation