Created On:  20 October 2009

Problem:

In a migration project the WRITE statement behaves differently from the origin.

Resolution:

The WRITE statement changes its behavior dependent on the selected dialect.

When using:
      $set dialect"OSVS"
or
      $set dialect"ENTCOBOL"
the statement
            WRITE REC
will delete the REC in
       FD  MYFILE LABEL RECORDS OMITTED.
01 REC PIC X(80).
accordingly to the OSVS COBOL resp. Enterprise COBOL on the mainframe. When using
      *set dialect"MF"
the statement
            WRITE REC
will keep REC unchanged.

If the dialect is unsupported, where the sources came from, either choose a better dialect to be closer to the origin or some code may need to be added to the WRITE statement.
Incident #2356068