Agreed.
I was following the style of the original code sample.
For simple file naming, you are quite correct. 'Sort' as used here is, indeed, pointless.
However, if my files were foolishly named something like foo_xxxxxxx_1.gz foo_xxxxxxx_2.gz foo_xxxxxxx_3.gz foo_xxxxxxx_4.gz foo_xxxxxxx_5.gz foo_xxxxxxx_6.gz foo_xxxxxxx_7.gz foo_xxxxxxx_8.gz foo_xxxxxxx_9.gz foo_xxxxxxx_10.gz foo_xxxxxxx_11.gz foo_xxxxxxx_12.gz then most simple uses of 'sort' (including file globbing) will cause file numbers 10, 11, and 12 to sort prior to file number 2. "Sufficiently clever" use of 'ls' and 'sort' could overcome this, although my preference would be to simply rename the files...
> for x in `ls $DUMPDIR/vald*.gz | sort` > do > sleep 60 > gunzip < $x > /VMP1/archive/ngepipe.dmp >done &
"ls" e "sort" are redundant.
for x in $DUMPDIR/vald*.gz ...
Regards Dimitre -- //www.freelists.org/webpage/oracle-l
-- Cheers, -- Mark Brinsmead Staff DBA, The Pythian Group http://www.pythian.com/blogs