[Date Prev][Date Next][Subject Prev][Subject Next][
Date Index][
Subject Index]
Re: Strange SA/NV behavior--BK is culprit
- Subject: Re: Strange SA/NV behavior--BK is culprit
- From: Carl Distefano cld@xxxxxxxx
- Date: Sat, 17 Oct 2009 16:31:17 -0400
Reply to note from Paul Lagasse Sat, 17 Oct
2009 14:52:06 -0400
> Before that copying occurs, FILE.BAK is older (has fewer or
> different edits) than FILE. If I use a routine to force VA$MO
> to 1 to ensure backups in those few instances (such as a
> changed case and the like) where Xy4 has not registered the
> change to the open FILE, then FILE will always be backed up
> even if I've made no changes to FILE.
Not true. The file will not be backed up (copied to .BAK) unless
there are changes to the original file that set VA$MO to 1. And
then, what is being backed up is not those changes, but the previous
disk write of the original file, which is what you want. Try the
routine I posted earlier today. Execute it repeatedly against an
open file without making changes to the file. You'll see that
the .BAK file is NOT updated. What you're missing, I think, is that
immediately after you SAve a file (force an actual disk write),
VA$MO is 0 -- and the backup COPY/NV is only invoked if VA$MO is 1
(i.e., changes were made but *not* written to disk).
--
Carl Distefano
cld@xxxxxxxx