

Using the Schema and Subschema Compilers › Coding DDL Schema and Subschema Statements › Statement Components
Statement Components
Five Components
Most DDL statements consist of five components, in the following order (exceptions are presented later):
- Verb (required) designates the specific operation to be performed by the statement: ADD, MODIFY, REPLACE, DELETE, DISPLAY, or PUNCH. Acceptable verb synonyms are shown in the following table.
|
Verb
|
Synonym
|
|
ADD
|
CREATE
|
|
MODIFY
|
ALTER
|
|
DELETE
|
DROP
|
- Entity type (required) identifies the type of data in the dictionary that the selected operation will affect: SCHEMA, AREA, RECORD, SET, SUBSCHEMA, LOGICAL RECORD, or PATH-GROUP.
- Entity occurrence name (required) identifies a specific instance of the named entity type.
- Optional clauses provide qualifying data for each component occurrence. Optional clauses can be specified in any order, unless individual clause explanations state otherwise.
- Period (required) signifies the end of the statement. The period can immediately follow the last word in the statement, can be separated from the last word by blanks, or can appear on a separate line.
If you specify the SEMICOLON ALTERNATE clause of the SET OPTIONS compiler-directive statement, both the period (.) and the semicolon (;) will be recognized as statement terminators.
Example Statement
The following example illustrates the parts of the typical DDL statement:
ADD SCHEMA EMPSCHM MEMO DATE IS 04/30/92 .
▲ ▲ ▲ ▲ ▲ ▲
│ │ │ └───────────────────┘ │
verb entity entity optional clause terminating
type occurrence period
name
Statement Exceptions
Exceptions to the syntax format rule stated above are clearly indicated in both the syntax layouts and the syntax explanations of the individual statements. Exceptions include the following:
- DELETE operations, which must not contain optional clauses (other than those needed to uniquely qualify the entity, such as VERSION, or satisfy security requirements, that is, PREPARED BY)
- VALIDATE, GENERATE, and REGENERATE, which do not name entities
- Carriage control statements (for compiler listings)
- Compiler-directive statements
Copyright © 2014 CA.
All rights reserved.
 
|
|