10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
In the awk below I am trying to cp and paste each matching line in f2 to $3 in f1 if $2 of f1 is in the line in f2 somewhere. There will always be a match (usually more then 1) and my actual data is much larger (several hundreds of lines) in both f1 and f2. When the line in f2 is pasted to $3 in... (4 Replies)
Discussion started by: cmccabe
4 Replies
2. Shell Programming and Scripting
Hi,
Anyone can help on how to append a file1.txt into file2.txt after line 3 using sed command.
file1.txt
1. testa
2. testb
3. testc
4. testd
5. test5
6. test6
file2.txt
break here
this is a test
break end here
output
1. testa
2. testb (1 Reply)
Discussion started by: fspalero
1 Replies
3. Shell Programming and Scripting
Hi,
I had generated a report in my tool as followsoutput.txt
43.35
9
i needed the script to generate a new file like below
i want to append the text to each of these lines of my filenewoutputfile.txt should be
Total Amount : 43.35
Record Count:9
Regards,
Vasa Saikumar.
... (2 Replies)
Discussion started by: hemanthsaikumar
2 Replies
4. UNIX for Dummies Questions & Answers
I would like to add a line to the end of a single column text file. How do I go about doing that?
Input:
BEGIN
1
2
3
Output:
BEGIN
1
2
3
END
Thanks! (1 Reply)
Discussion started by: evelibertine
1 Replies
5. Shell Programming and Scripting
After I create printer queues in AIX, I have to append a filter file location within that printers custom file. within lets say test_queue.txt I need to find the row that starts with :699 and then I need to append on the end the string /usr/local/bin/k_portrait.sh.
Now I've gotten the sed... (2 Replies)
Discussion started by: peachclift
2 Replies
6. Shell Programming and Scripting
I've scoured the internet with mixed results. As an amateur I turn to the great minds here.
I have a text file of 80 or so lines. I want to add ".pdf" to the end of each line. (For now that's it)
Most of the internet points toward using "sed". I don't know coding but can figure things out... (4 Replies)
Discussion started by: spacebase
4 Replies
7. Shell Programming and Scripting
hi,
I've a file with some text in it, i need to append few strings in the beginning and end of each row.
--in file
richie
matt
..
--out file
hi, 'richie' is here
hi, 'matt' is here
...
I tried with awk command, but it fails because of '
Thanks (2 Replies)
Discussion started by: dvah
2 Replies
8. Shell Programming and Scripting
Hi guys, plz tell me how to achieve this
how to delete the lines in a file using sed command (6 Replies)
Discussion started by: hari908
6 Replies
9. UNIX for Dummies Questions & Answers
Hi all
I tried this on an old version of sed on NCR Unix MP-RAS:
sed -e "s/$/nnn/" file1 >file2
This file (file1):
the cat sat on the mat.
the cat sat on the mat.
the cat sat on the mat.
becomes this (file2):
the cat sat on the mat.nnn
the cat sat on the mat.nnn
nnn
the... (3 Replies)
Discussion started by: jgrogan
3 Replies
10. Shell Programming and Scripting
Hi
I need to append some text @ end of the first line in a file.
like
myfile.txt
list = a,b,c
list.a=some..
I give the arg "d" . now it append at end of first line
list=a,b,c,d
list.a=some...
Please help me out this (7 Replies)
Discussion started by: catgovind
7 Replies