10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
hi all,
trying this using shell/bash with sed/awk/grep
I have two files, one containing one column, the other containing multiple columns (comma delimited).
file1.txt
abc12345
def12345
ghi54321
...
file2.txt
abc1,text1,texta
abc,text2,textb
def123,text3,textc
gh,text4,textd... (6 Replies)
Discussion started by: shogun1970
6 Replies
2. Shell Programming and Scripting
Hi,
I tried the following options but was unable to delete blank lines from file
Input file = temp.hash.txt
temp.hash.txt content
90
0
89.56
0
0
57575.4544
56.89 (9 Replies)
Discussion started by: uuuunnnn
9 Replies
3. Shell Programming and Scripting
Hi
I have a text file like below. THe content of the text will vary.
Entire text file have four consecutive lines followed with blank line.
I want to delete the occurrence of the two consicutive lines in the text file. I don't have pattern to match and delete. Just i need to delete all... (5 Replies)
Discussion started by: RJSKR28
5 Replies
4. Shell Programming and Scripting
I have 2 TXT files with with 8 columns in them(tab separated). First file has 2000 entries whereas 2nd file has 300 entries.
The first file has ALL the lines of second file. Now I need to remove those 300 lines (which are in both files) from first file so that first file's line count become... (2 Replies)
Discussion started by: prvnrk
2 Replies
5. Shell Programming and Scripting
it will grep for a line and then delete these line. how do i begin to write this script if theres no available one? (3 Replies)
Discussion started by: garfish
3 Replies
6. UNIX for Dummies Questions & Answers
Hi everybody!
I need to delete several vertical lines in a huge text file.
It should work like the example below. Delete the vertical lines 2 and 8.
123456789
masldfjla
afsajfwel
sajfljsaf
safsarfrl
sajfeljwq
1345679
msldfja
asajfwl
sjfljsf
sfsarfl
sjfeljq
Is there a... (11 Replies)
Discussion started by: relaxo
11 Replies
7. Shell Programming and Scripting
Hi
I want to delete first five and last five lines in text files without opening the file and also i want to keep the same file name for all the files.
Thanks in advance!!!
Ragav (10 Replies)
Discussion started by: ragavendran31
10 Replies
8. Shell Programming and Scripting
Hello,
Hello Firends,
I have file like below. I want to remove selected blocks say abc,pqr,lst. how can i remove those blocks from file.
zone abc {
blah
blah
blah }
zone xyz {
blah
blah
blah }
zone pqr {
blah
blah
blah } (4 Replies)
Discussion started by: nrbhole
4 Replies
9. Shell Programming and Scripting
hello all
I have bunch of files containing lines of text that surrounding by <# .......#> tags
I like to delete this lines from the text files whiteout open the files , can it be done with sed ?
or other unix tool (perl mybe )? (2 Replies)
Discussion started by: umen
2 Replies
10. Programming
Hi, experts,
I would like to create a function that can calculate the total number of lines in a saved text file and delete specific lines in that particular file (I only want the last few lines). Hav anybody have the experience and giv me a hand in this? (9 Replies)
Discussion started by: dniz
9 Replies