COPYFILE ... a fast file copier. Written by Stan Sieler COPYFILE may be run in either of two ways: (1) interactively ... just run COPYFILE. You will be prompted for input and output file names. If you hit 'return' when asked for an input file name, COPYFILE will terminate. If you want to read from $STDIN, then enter: $STDIN or $STDINX. (2) from a UDC ... sample udc is: copyfile FROM=" ", TO=" ", PARM=0 RUN COPYFILE.PUB.ALLEGRO;INFO="!FROM !TO";PARM=!PARM To use the udc, try: COPYFILE FOO,FUM This will copy the file FOO into a new file called FUM In both modes, if the input file name has a group (or group & account) specified, then the default output file name is the input name without the group.account. For example, if the input file name is FOO.FIE.FUM, then the default output file name is FOO.logongroup.logonacct and will be used as the output file name if you hit "return" when prompted. If the input file is a database root file, then COPYFILE will copy the entire database IF you are running in batch, or you invoked COPYFILE with an INFO string, or if you answer YES when COPYFILE asks you if it should copy the whole thing, or if PARM bit 14 = 1. COPYFILE is aware of Third Party Indexing, and will copy any index files it can find. For simple 'from' files, an NS/3000 node name is allowed (e.g.: FROM:NODENAME). If COPYFILE is run in batch, or with a PARM=1, then it assumes that you always want to purge the old copy of the destination file, should one exist. NOTE: in either mode, options may follow the 'TO' filename, in any order (and in any case): EXTents # ... desired # extents for output file FAKE ... don't actually do the copy FILECODE # | xxx ... desired filecode for new file QUIET ... you don't like informative messages TEMP ... create output file in TEMP domain YES ... auto answer any questions with 'YES' The PARM bits can be combined. For example, PARM = 3 (bits 14 and 15) means: automatically purge old file, and if source file is a database then copy the entire database without asking. The output file name may have an optional "TEMP" after it: outputfilename [ TEMP ] The TEMP option results in a new file in the job/session temporary domain instead of a permanent disc file. NS/3000 nodenames are not supported (e.g.: FROM:NODE). The following PARM bits are recognized by COPYFILE: Bit# Name Meaning ---- ---------------- ------------------------------- 15 always'purge You want to purge OLD destination files 14 always'copy'db You want to copy entire databases 13 quiet'copy You don't like informative messages 12 suppress'copy'db You DONT want to copy entire databases 11 show'times You want CPU & elapsed times shown