Hai friends why we need to read a file before re-write a record?
Hi, For Rewrite, the file has to be opened in I-O mode. REWRITE is used to update records. Rewrite statement will update the last read record. Hence, we have to read the record to be updated first. Hope this clarifies.