![]() |
![]() |
ALLBASE/SQL Database Administration Guide: HP 9000 Computer Systems > Chapter 2 Logical Design![]() Defining the DBEnvironment Scope |
|
ALLBASE/SQL databases are contained in a DBEnvironment. A DBEnvironment is one or more databases that share the same system catalog and the same logging and recovery. Databases within a DBEnvironment can be related to each other through ISQL and in applications if security allows it. Databases that are contained in separate DBEnvironments cannot be linked to each other. An interactive user or application program can only access one DBEnvironment at a time. (However, the same application can maintain several DBEnvironment connections and access different DBEnvironments in sequence. Refer to the section "Using Multiple Connections and Transactions with Timeouts" in the ALLBASE/SQL Reference Manual chapter "Using ALLBASE/SQL.") As shown in Figure 2-10 “DBEnvironment used by Integrated Peripherals, Inc.”, the DBEnvironment used by Integrated Peripherals, Inc., has three databases. Figure 2-10 DBEnvironment used by Integrated Peripherals, Inc. ![]() The PurchDB database has been designed in the present chapter; the other databases are included to illustrate the use of multiple databases in a single DBEnvironment. All three databases are placed in a single DBEnvironment because the data, although used separately in most applications, is sometimes used together in reports and global applications. The number of databases that you can put in a DBEnvironment is limited only by the amount of disk space available to you. There are some reasons why you might create separate DBEnvironments for databases.
Databases are logically separated by the owner name of the tables, indexes, and views. They can also be physically separated for independent manipulation through selective allocation of space using DBEFiles and DBEFileSets. The allocation of space or physical design of the database is covered in the next chapter. The DBEnvironment designed for Integrated Peripherals, Inc. is the basis for the sample DBEnvironment PartsDBE, which is included with the ALLBASE/SQL product. Most of the examples in the rest of this book refer to tables or other objects in PartsDBE. |