HP 3000 Manuals

USING COMMANDS TO DEFINE OTHER FILE STRUCTURES [ DICTIONARY 3000 ] MPE/iX 5.0 Documentation


DICTIONARY 3000

USING COMMANDS TO DEFINE OTHER FILE STRUCTURES 

MPE files, MPER files, KSAM files and VPLUS forms files can also be
defined in the Dictionary.  The DICTDBM commands are used to create and
define these files in the Dictionary.

For MPE, MPER, and KSAM files, you define the record layout for the file.
In the Dictionary, each field in the record is created as a data element
with characteristics such as type, size, and so forth.  For the VPLUS
forms file, each form is created as a file, and the fields within each
form are created as data elements.  The definitions for a VPLUS forms
file is completed by establishing the relationship between the VPLUS
forms file and each form in the forms file.  This relationship is also a
hierarchical relationship and is established using the RELATE command.
(Refer to Section IV of this manual for a description of this command.)
This hierarchical relationship is summarized in Figure 3-2.
_________________________________________________________________________
|                                                                       |
|                                                                       |
|                              VPLUS                                    |
|                              FORMS          <----  PARENT file        |
|                               FILE                                    |
|                                |                                      |
|                   -------------|-------------                         |
|                  |                           |                        |
|                  |                           |                        |
|                  |                           |                        |
|                 FORM                        FORM    <----  CHILD files|
|                 FILES ...                   FILES ...                 |
|                  |                           |                        |
|                  |                           |                        |
|                  |                           |                        |
|                 data                        data                      |
|               elements ...                elements...                 |
|                                                                       |
_________________________________________________________________________

          Figure 3-2.  Summary of Hierarchical Structure for a VPLUS Forms File 

The VPLUS forms file is the top of the structure and is the PARENT file.
Each FORM file is related to the VPLUS file and is considered a CHILD
file.  In this structure, the PARENT file cannot have data elements
directly associated with it.

The following description outlines the steps involved when the DICTDBM
commands are used to define other file structures.  A complete
description including examples for all the commands is given in Section
IV of this manual.

Creating MPE, MPER, KSAM, and VPLUS Elements and Files 

Creating files and data elements for these structures is similar to
creating them for a database.  An element or a file must be defined in
your Dictionary before you can associate or relate it to another entry.
To define the entries, use the command string CREATE ELEMENT or CREATE
FILE. The name used for the element or the file must be unique.  Use the
REPEAT option before the command string to create entries for many
elements or files without having to reenter the command.  A definition
for the VPLUS forms file must be created before the hierarchical
relationship between the forms file and the forms can be created.

After the entries are created, use the LIST or DISPLAY commands to
display the entry.  Entries can be deleted by using the PURGE command,
and can be changed by using the MODIFY or RENAME command.  To define the
CHILD elements (fields) within a PARENT data element, use the RELATE
ELEMENT command string.

Adding Data Elements to Files 

The ADD command is used to associate data elements to files.  Use the
command string ADD FILE to define this association.

Elements may not be directly associated to the VPLUS forms file.  DICTDBM
will not accept this and will issue an error message.  The elements must
be associated with the file according to the record layout or form
design.  When elements are associated with a KSAM file, you must identify
which element or elements are the keys for the file.

To display an alphabetized listing of association entries, use the REPORT
command.  For a form, the list shows the elements associated with the
form; for a VPLUS forms file, the list shows all the elements associated
with the CHILD files.  The SHOW command is used to display each file and
the elements associated with it.  It also gives a complete listing of the
forms in a VPLUS file and optionally, the elements within each form.  The
forms are displayed in the physical order of their relationship to the
VPLUS forms file, and the elements are in the physical order of their
association with the form.  For KSAM files, the SHOW command indicates
key elements with an asterisk, "*" .

An association entry can be deleted with the DELETE command or changed
with the UPDATE command.  If you want to change the physical order in
which the association entries were made, use the RESEQUENCE command.

Relating Forms to a VPLUS Forms File 

The hierarchical relationship between the forms and a VPLUS forms file is
established using the RELATE command.  The command string RELATE FILE is
used to define this relationship.  This command allows more than one form
to be related to the VPLUS file during the command cycle.  Use the SHOW
command or the REPORT command to display the relationship entries.

The relationship entry is deleted by using the REMOVE command and is
changed by using the CHANGE command.  Use the REORDER command to change
the physical order in which the CHILD files are related to the PARENT
file.

Security for MPE, KSAM, and VPLUS Files 

Security as defined and used for IMAGE databases is not applicable to MPE
files, KSAM files, and VPLUS forms files.  For these files "lockwords"
are used for protection.  The CREATE command is used to define a security
class for the lockword.  In the Dictionary, the lockword for the file is
called the PASSWORD. After a class is created for the lockword, the ADD
CLASS-FILE command string is used to associate the security class with
the file.

To display the security class entries, use either the LIST or DISPLAY
command.  If you want to delete an entry from the Dictionary, use the
PURGE command.  To change the entry, the MODIFY command or the RENAME
command is used.


MPE/iX 5.0 Documentation