Maintaining A Dictionary - HP DDL D40 Reference Manual

Data definition language
Table of Contents

Advertisement

Introduction to DDL
Host-language source files used by native programs and shared with TNS programs
must be generated using a version D40 or later DDL compiler. Host-language source
files supplied by HP have already been generated by the correct version of the DDL
compiler.
If your native programs do not share host-language source files with TNS programs,
you can direct DDL to align data optimally for the native RISC environment. To do so,
specify the ?FIELDALIGN_SHARED8 command when storing data in a DDL dictionary.
While DDL source files generated with shared8 alignment can be used by TNS and
native programs, the performance of TNS programs is degraded. Refer to
DDL Compiler

Maintaining a Dictionary

After a dictionary is created, change is inevitable. You might need to add new objects
or to change or delete existing objects. DDL source schema files help you perform
these maintenance functions.
DDL can generate source schema statements from the dictionary and write these
statements to a DDL source schema file. In its simplest role, a DDL source schema file
provides a backup schema for dictionaries created from the DDL compiler. Suppose
the dictionary but not the original schema has been changed, or suppose the original
schema is lost. In either case, DDL can generate a new schema that accurately
reflects the current dictionary and write this schema to a DDL source schema file.
You should not attempt to back up a dictionary that is part of a Pathmaker catalog
using this technique. Pathmaker dictionaries contain application design information that
is not in generated DDL schemas.
DDL can compile the entire DDL source schema file into a new dictionary just as it
compiled the original schema. DDL can also compile selected sections of a source
schema file (or of any source schema) and add them to an existing dictionary.
A DDL source schema file is also useful for modifying dictionary objects that are used,
or referenced, by other objects. To change or delete an object that is referenced, you
must first delete all the objects that refer to that object, change the referenced object,
and then reenter the deleted objects. DDL can generate all the source code necessary
to perform these operations and write the source code to an open DDL source schema
file. To update the dictionary, you need only compile this file, first modifying it if
necessary.
Figure 1-5
on page 1-11 illustrates two typical maintenance operations:
1. Add a new object to the dictionary.
Define the new object in a source schema file. If you add the new object definition
to your original schema, precede the definition with a SECTION command. Then
run DDL interactively, and use a SOURCE command to compile the definition in
the source schema and write the new object to the dictionary.
Data Definition Language (DDL) Reference Manual—426798-002
Commands, for more details.
1- 10
Maintaining a Dictionary
Section 9,

Advertisement

Table of Contents
loading

Table of Contents