- 1.1 Brief History of DB2
- 1.2 The Role of DB2 in the Information On Demand World
- 1.3 DB2 EDITIONS
- 1.4 DB2 Clients
- 1.5 Try-and-Buy Versions
- 1.6 Host Connectivity
- 1.7 Federation Support
- 1.8 Replication Support
- 1.9 IBM WebSphere Federation Server and WebSphere Replication Server
- 1.10 Special Package Offerings for Developers
- 1.11 DB2 Syntax Diagram Conventions
- 1.12 Case Study
- 1.13 Summary
- 1.14 Review Questions
1.11 DB2 Syntax Diagram Conventions
DB2 supports a comprehensive set of statements for data access and manipulation. These statements are documented online in the DB2 Information Center, which gives you access to all information about DB2 as well as major DB2 features and components. It can be conveniently accessed by using a browser, as shown in Figure 1.15. The DB2 Information Center is also available at http://publib.boulder.ibm.com/infocenter/db2luw/v9r5/index.jsp.
Figure 1.15 The DB2 Information Center
You can find the syntax of any commands or statements we introduce in this book in the DB2 Information Center. Understanding how to read the syntax diagrams will help you use the numerous options available with many of the statements.
Syntax diagrams are all read from left to right and top to bottom, following the path of each line. Table 1.6 summarizes a few of the most commonly used symbols in a syntax diagram.
Table 1.6. Summary of Some Symbols Used in Syntax Diagrams
Symbol |
Description |
>>--- |
Indicates the beginning of a syntax diagram. |
---> |
Indicates that the syntax is continued on the next line. |
>--- |
Indicates that the syntax is continued from the previous line. |
--->< |
Indicates the end of a syntax diagram. |
When a mandatory field is required, it appears on the horizontal line (the main path) like this.
>>-mandatory_field--------------------------------------><
Optional fields appear below the main path.
>>-mandatory_field--+----------------+------------------>< '-optional_field-'
If an optional field appears above the main path, it means that it is the default option.
.-default_field-. >>-mandatory_field--+---------------+------------------->< '-optional_field-'
If two or more mandatory choices are available, one of the mandatory choices will appear in the main path, and the rest will appear in a stack. You must choose one of these options.
>>-mandatory_field--+-mandatory_choice1-+--------------->< '-mandatory_choice2-'
An arrow returning to the left, above the main line, indicates an option can be repeated. In this example, repeated options are separated by one or more blanks.
.-----------------. V | >>-mandatory_field----repeatable_field-+----------------><
If the repeat arrow contains a comma, you must separate repeated items with a comma.
.-,---------------. V | >>-mandatory_field----repeatable_field-+----------------><
You should now feel comfortable reading syntax diagrams in the DB2 documentation. Browse through the DB2 online documentation and review some examples there.