next up previous contents index
Next: Access to TMS Up: A tutorial introduction Previous: Processing multiple entries

Deleting multiple files using the FATMEN shell

Neither the FORTRAN routine FMRM nor the shell commmand rm accept wild-cards in the generic-name. This is deliberate and protects against mis-use such as

   rm *

or worse

   rm */*
which would remove all files in all directories, subject to the normal protection rules, and generate a lot of work for the servers.

Multiple files can be deleted as shown in the previous FORTRAN example, or via a 2-stage operation in the shell. If, for example, one wished to delete all files belonging to JAMIE, one could type

Using the SEARCH command to prepare a macro

FM>SEARCH */* USER=JAMIE -D OUTPUT=DELETE.KUMAC
FM>EXEC DELETE

To approximate to the previous FORTRAN example, one could use

Using the SEARCH command to delete robot tapes

FM>SEARCH //CERN/DELPHI/P01_*/RAWD/NONE/Y90V00/E*/L*/* VID=I* -D _
   OUTPUT=DELROB.KUMAC
FM>EDIT DELROB | Now add -FU to each line
FM>EXEC DELROB

Note that the removal of entries from the catalogue should always be done with extreme care.


Janne Saarela
Mon May 15 09:59:59 METDST 1995