Hi Guys,
I am very much new to UNIX. I dont have much basics of coding in UNIX, so please help me out of thi ssituation.
I have a file say for ex: ABC.dtd and it contains "|" delimited data as
test1|testing|test3|moving
past1|runing|test4|going
I need to add a column at the end of each line as shown below.
test1|testing|test3|moving|D
past1|runing|test4|going|D
for this purpose I am using the command :searches the end of the line i.e "$" and then replaces with "D".
%s/$/D/g
The problem is before the search begins, first I need to implement a function that picks up the file from the specified location and performs search and replace and pushes back thhe file to the original location.
This overall function I need to implement in a ksh script.
Could you please help me out of this?????????
Thanks in advance.
ruthless