On Fri, 13 Feb 2004, Rob Dixon wrote: > > As far as I know 'rename' is atomic, so: > > my $number; > > do { > $number++; > my $test = "$report.$number"; > } until rename $fn, $test; > > HTH, > > Rob
My Perl book indicates that if a file with the name in $test exists, it is destroyed and replaced. I don't want to replace an existing file. Every other method other than sysopen seems to have this effect as well. I.e. rename, File::Copy "move", etc. -- Maranatha! John McKown -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>