ACCEPT
statement
The ACCEPT statement transfers data or
system date-related
information into the data area referenced by the specified identifier.
There is no editing or error checking of the incoming data.
Data transfer
Format 1 transfers data from an input source into the data item referenced by identifier-1 (the receiving area). When the FROM phrase is omitted, the system input device is assumed.
System date-related information transfer
System information contained in the specified conceptual data items DATE, DATE YYYYMMDD, DAY, DAY YYYYDDD, DAY-OF-WEEK, or TIME, can be transferred into the data item referenced by identifier-2 . The transfer must follow the rules for the MOVE statement without the CORRESPONDING phrase.
DATE, DATE YYYYMMDD, DAY, DAY YYYYDDD, DAY-OF-WEEK, and TIME
The conceptual data items DATE, DATE YYYYMMDD, DAY, DAY YYYYDDD, DAY-OF-WEEK, and TIME implicitly have USAGE DISPLAY. Because these are conceptual data items, they cannot be described in the COBOL program.
Example of the ACCEPT statement
This topic lists an example for the ACCEPT statement.