Quote:
Originally Posted by Ammad
Dear all,
Is it possible to replace "\" with "blank space" using sed.
thanks
|
Yes!!
.
Oh!!!--did you mean to ask HOW??
The trick here is that any character can be used as the separator in the SED "s" (substitute) construct. So, just use this general form:
sed 's#old#new#' (add a "g" to make it replace all "old" with "new".) old or new can now contain the "/".
The other method is to escape the "/" so that it is not interpreted as a separator. eg use "\/" to get a literal "/".
OOPS--I read "/" instead of "\"---see below.