I am tryinf to something relatively simple but seem unable to get this script working. I simply want to replace the number associated with a certain work. I am using sed. However when I incorporate the working sed command into my script it does not work any longer.
for i in `seq 0 9`
Result=`expr $i + $y`
This is the error:
sed: -e expression #1, char 1: unknown command: `''
Could someone please point out what is going wrong...
I think you should get rid of some of the variables and quotes. Instead of "$f", why don't you write something like
OK thanks..that doesnt error now, but I find that I'm not replacing the text as desired!
The file that I am looking at looks like:
Its not pikcing out the Lipid 0 - any idea?
It does. In the first loop, "LIPID 0" is replaced with "LIPID 1000".
I am not sure what is going on with the scheme as it loops around and when I look at the output lipid 0 is still there. Should I be outputting to a different file? I need to loop around 100 times.
I decreased the number of loops to 2, to make the output a little shorter for the post. But then, it will look as follows, and that's precisely what it's supposed to do. If you want something different, you'll have to say so. I also added a line to indicate where the loop begins:
|All times are GMT -5. The time now is 01:13 AM.|