Hi, This is my first email to beginner's Perl and sincerely hope I am sending this message to the right place.
I want to delete some DB backup files using UNC pathing and perl. My code segment, which does not work, is listed below. I do not get any errors when I run this piece of code however, the files are not deleted either. Does anyone know what is wrong with the code? The file permissions are open to the world, the file was not in use, and I did try using (<\\\\myserver\\e$\\LS_DbBackUp\\stdby30dev\\*.trn <file:///\\myserver\e$\LS_DbBackUp\stdby30dev\*.trn> > ). What I found out so far is that my code works with Perl version 5.005_03, binary build 522 but not with ActivePerl-5.6.1-535-MSWin32-x86.msi or ActivePerl-5.8.0.806-MSWin32-x86.msi. Has anyone else come across this issue? What did you do to resolve it? Code segment foreach $file (<\\\\myserver\\e\\LS_DbBackUp\\stdby30dev\\*.trn <file:///\\myserver\e\LS_DbBackUp\stdby30dev\*.trn> > ) { unlink($file) || warn "file not deleted $file $!"; } Thanks, Shirley