Click here to Skip to main content
15,881,172 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi People,

I want to change the content of the data using shell script.
The script run and will change all the 530, I just want to change only 530, not INP50101530

INQ|530|INP50103245|0|01/10/2014|0|E7PW44TU7|TODRT|INP50101530|A|DTA|17/10/2014|OGF|IN410501A|23/01/2014|24/01/2014|1|R|F|530|IND1WPG|N|40|3|1009|N|A|136800|136800|11340|526.154|65.769231|INR|INP00804|23/01/2014|23/01/2014||22/01/2014|23/01/2014||||N|1| |IN|OP|23/01/2014|MBI|210|TRD|Finish Line|I


the script;

grep -rl '530' /home/daimler_dubai/aqilah/daimler/*txt | xargs sed -i 's/530/MBP/g'


Thanks in advance
Posted

1 solution

Try searching for : '|530|'
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900