Sun Studio 12: Fortran Programming Guide

2.1.2.1 Opened as Scratch

Specifying STATUS=’SCRATCH’ in the OPEN statement opens a file with a name of the form tmp.FAAAxnnnnn, where nnnnn is replaced by the current process ID, AAA is a string of three characters, and x is a letter; the AAA and x make the file name unique. This file is deleted upon termination of the program or execution of a CLOSE statement. When compiling in FORTRAN 77 compatibility mode (-f77), you can specify STATUS=’KEEP’ in the CLOSE statement to preserve the scratch file. (This is a non-standard extension.)