Rational Programming Patterns for System z

Adding external resources to a Program

External resources are files represented by Data Structures or Reports. To add external resources in a Program, you must specify their logical and physical characteristics and the way they are to be used in the Program.

Procedure

  1. Open the -CD Lines tab of a Program.
  2. Insert a CD line by clicking Add CD Line. The following selection box opens up (figure 1):
    Figure 1. Selection of a Data Structure or a Report
    Selection of a Data Structure or a Report, or both.
    In this selection box, you can check one or more Data Structures or Reports, or both. If the Data Structure or Report you want to call:
    • Is displayed in the selection box, click its corresponding check box and click OK.
      Note: By default, a Data Structure is inserted as a sequential file with fixed-length records. It contains all of the Data Structure records, with the Data Elements in internal format, without the optional Data Elements.
    • Does not exist yet, click New Data Structure or New Report. In the creation wizard which opens up, enter the name and label of the Report and click OK. The new instance is then displayed in the selection list. If you select it and click OK, it is called on a -CD Line.
  3. Complement the -CD line if necessary. To insert a:
    1. Data Structure in an existing Data Structure -CD line used to specify a composite Data Structure. Select this -CD line on the first level of the tree, or a Data Structure call line nested under the -CD line (on the second level of the tree). Click Add Data Structure. In the selection box which opens up:
      • Check that the instance you want to call in the Program and click OK.
      • To call an instance which does not exist yet, click the New Data Structure. In the creation wizard which opens up, enter the name and label of the Data Structure and click OK. The new Data Structure is then displayed in the selection list. If you select it and click OK, it is called in the selected -CD Lines.
    2. Report in an existing Report -CD line in order to specify a composite Report. Select this -CD line on the first level of the tree, or a Report call line nested under the -CD line (on the second level of the tree). Click Add Report. In the selection box which opens up:
      • Check that the instance you want to call in the Program and click OK.
      • Or, to call an instance which does not exist yet, click New Report. In the creation wizard which opens up, enter the name and label of the Report and click OK. The new Report is then displayed in the selection list. If you select it and click OK, it is called in the selected -CD Lines.
    3. Segment in a Data Structure already called in the Program, select this Data Structure call line or a Segment call line and click Add Segment. In the selection box which opens up:
      • Check that the instance you want to call in the Program and click OK.
      • Or, to call an instance which does not exist yet, click New Segment. In the creation wizard which opens up, enter the name and label of the Segment and click OK. The new Segment is then displayed in the selection list. If you select it and click OK, it is nested in the selected Data Structure call line.

What to do next

After the -CD Lines have been inserted, you can modify their default characteristics in the sections which automatically open up, depending on your selection:

Terms of use | Feedback

This information center is powered by Eclipse technology. (http://www.eclipse.org)