I am trying to remove or replace various extraneous characters from a file so that subsequent processes work correctly. The characters that is giving me trouble is the apostrophe '.
The command I 'm trying is
sed 's/\'//g' ${IN_WRK_DIR}/file1 > ${IN_WRK_DIR}/file2
in a Korn script on HP Unix.
I do need to retain other nonalpha-numeric characters.
But in using cat you cat have to make fork and exec system calls for the new process, both are expensive calls, by using < to redirect stdin you do not need to make these calls and so as vergsh99 pointed out it would be a UUOC.
Why do you think it would be any different if it were sed?