Previous Topic: ParametersNext Topic: Syntax


MOVE

The MOVE keyword moves data from the work buffer to the move buffer.

The move buffer is created and initialized with the first MOVE keyword encountered. It is initialized with the PADCHAR value, if supplied, otherwise it is initialized with low values. You use multiple MOVE statements to populate the move buffer. The rightmost position moved to determines the length of the move buffer. If the move buffer is greater than the output's maximum allowable record length, the move buffer is truncated to that value and the TRUNCRC value is returned. Otherwise, for variable record lengths, the move buffer length determines the length of the output record, and for fixed record lengths the move buffer is padded with the current PADCHAR value to the defined record length. The WRITE keyword must be used to actually write the move buffer to the output file(s). You use the CLEAR parameter value to reset all bytes in the current move buffer to the current PADCHAR value, and for variable output files, to reset the move buffer length to zero. The move buffer length is also set to zero for variable output files with each input record read.