Previous Topic: 5.2.2 A Single File and Multiple CyclesNext Topic: 5.2.2.2 Interleaving


5.2.2.1 Concatenation


The simple way to combine multiple file cycles for processing
is to concatenate them.  In this scenario, multiple cycles
are read to create a single SAS data set.  The program and
illustration in Figure 5.1 show the output from the
concatenation of two cycles of BATPGM.

DATA NEWFILE;
SET &PBATX..BATPGM01 &BATOX..BATPGM02;


           BATPGM01          NEWFILE                 BATPGM02

    +-------------+                           +-------------+
    |             |-+                       +-|             |
    +-------------+ |                       | +-------------+
    |             |-|                       |-|             |
    +-------------+ |                       | +-------------+
    |             |-|                       |-|             |
    +-------------+ |                       | +-------------+
                    |                       |-|             |
                    |                       | +-------------+
                    |                       |
                    |                       |
                    |                       |
                    |    +-------------+    |
                    |  +-|             |    |
                    |  | +-------------+    |
                    +--|-|             |    |
                       |-+-------------+    |
                       +-|             |    |
           ------------- +-------------+ ---|-------
                         |             |----|
                         +-------------+    |
                         |             |----|
                         +-------------+    |
                         |             |----|
                         +-------------+    |
                         |             |----+
                         +-------------+


Figure 5-1.  Concatenation of Two Cycles