HP 3000 Manuals

DETACH [ ALLBASE/Turbo CONNECT Administrator's Guide ] MPE/iX 5.0 Documentation


ALLBASE/Turbo CONNECT Administrator's Guide

DETACH 

Detaches a TurboIMAGE/XL database from a DBEnvironment.

Syntax 

DET[ACH]

Command Prerequisites 

 *  SET SQLDBE issued.
 *  SET TURBODB issued.
 *  DBA authority.
 *  Database attached.

Description 

Use the DETACH command to detach a TurboIMAGE/XL database from a
DBEnvironment.  SET TURBODB and SET SQLDBE commands must be issued before
the detach can take place.  The database named in the most recent SET
TURBODB is detached from the DBEnvironment named in the most recent SET
SQLDBE command.

You must detach the database before performing any restructuring tasks
and reattach when the restructuring is complete.  Also detach any
attached databases from a DBEnvironment before migrating back to an
earlier version of ALLBASE/SQL that does not support Turbo CONNECT.

When a database is detached, all mapping information about it is removed
from the ATCINFO file.  If it is the only database attached to the
DBEnvironment, the ATCINFO file itself is purged.  If the TurboIMAGE/XL
database is no longer attached to any DBEnvironment, the DBNameTC file is
also purged.

In addition, all mapped table definitions are removed from the
DBEnvironment system catalog.  All Turbo CONNECT views and user-created
views based on Turbo CONNECT tables and views are dropped.  Note that
DBUTIL can be used to purge and detach a database that is attached to a
DBEnvironment.

Example 

In this example, SALES is detached from PartsDBE. When this occurs, all
mapping information about SALES is removed from the ATCINFO file.  If
SALES is the only database attached to PartsDBE, the ATCINFO file itself
is purged.  If SALES is no longer attached to any DBEnvironment, the
SALESTC file is also purged.
_____________________________________
|                                   |
|     >>SET SQLDBE PARTSDBE         |
|     >>SET TURBODB SALES           |
|     >>DETACH                      |
|     >>                            |
_____________________________________



MPE/iX 5.0 Documentation