Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
number wraps back to 1.00 and continues to increment unless you specify the<br />
SRCOPT and SRCSEQ parameters on the copy command.<br />
If several copies to the same file are made with MBROPT(*ADD), you will have<br />
duplicate sequence numbers in the file. You can correct this using the Reorganize<br />
Physical <strong>File</strong> Member (RGZPFM)command.<br />
Date fields are initialized to zeros.<br />
When copying to or from a device, it is more efficient to use a device data file than<br />
a device source file. The copy function automatically adds or removes sequence<br />
number fields and date fields source sequence number and date fields as necessary.<br />
Copying database source files to device source files<br />
When you are copying to a device source file, the system removes the date fields<br />
and the sequence number fields from the start of the records.<br />
When copying to or from a device, it is more efficient to use a device data file than<br />
a device source file. The copy function automatically adds or removes source<br />
sequence number fields and date fields as necessary.<br />
Copying database source files to database source files<br />
You can copy between database source files by using the CPYSRCF or CPYF<br />
command. The CPYSRCF command may be easier to use because the parameter<br />
defaults are better suited for copying database source files.<br />
If you specify SRCOPT(*SEQNBR) to update the sequence numbers, the system<br />
considers the SRCSEQ parameter. The SRCSEQ parameter specifies the starting<br />
value that is assigned to the first record that is copied and the increment value.<br />
The defaults are 1.00 and 1.00. You can specify a whole number of no more than 4<br />
digits or a fraction of no more than 2 digits for the starting value and the<br />
increment value. (You must use a decimal point for fractions.)<br />
For example, if you specify SRCSEQ(100.50), then the records copied will have<br />
sequence numbers 100.00, 100.50, 101.00, 101.50, and so on.<br />
Suppose that you have a file that contains more than 9999 records. Use a fractional<br />
increment value so that each record has a unique sequence number. If you specify<br />
a starting value of .01 and an increment value of .01, the maximum number of<br />
records copied with unique sequence numbers is 999 999. When the maximum<br />
sequence number is exceeded (9999.99), all remaining records on that copy are<br />
initialized to 9999.99. The system does not wrap back to 1.00.<br />
If the database source file that you are copying to has only an arrival sequence<br />
access path, the records are always physically placed at the end of the file.<br />
(Because the file does not have a keyed sequence access path, you cannot insert<br />
records into the middle of the file keyed access path.)<br />
Chapter 4. Copying files 121