ACUCOBOL-GT solves this problem by providing a transaction logging facility. All file operations that are part of a transaction are logged. Once logged, they can either be committed or rolled back (undone) by the program.
If a program dies, or the system fails, the log file can be used to reconstruct complete transactions, thus returning all files to a consistent state.
Transaction logging thus offers these two facilities: