if you have a large file that is too large to pass to xargs, you can bring it up into chunks. For instance: cat file.txt | xargs -L 3 echo will execute echo on 3 lines at a time.
comm -23 file1 file2 shows lines only in file1 (-2 don’t show unique lines in file2, -3 …rtfm)
sed ‘s/n//g’ <–does not work Because sed reads input a line at a time, and thus, won’t see n See http://backreference.org/2009/12/23/how-to-match-newlines-in-sed/
If you were to want to read the contents of a file in ksh, and the file just so happens to contain problematic characters like *, do this in your script: set -f prior to doing: sql=`cat $sql_file`; More info (from http://www.computing.net/answers/unix/escaping-in-korn-shell/7016.html): echo $- ism set -f echo $- isfm echo $sample test* set +f […]