10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi, i have file file.txt with data like:
START
03:11:30 a
03:11:40 b
END
START
03:13:30 eee
03:13:35 fff
END
jjjjjjjjjjjjjjjjjjjjj
START
03:14:30 eee
03:15:30 fff
END
ggggggggggg
iiiiiiiiiiiiiiiiiiiiiiiii
I want the below output
START (13 Replies)
Discussion started by: Jyotshna
13 Replies
2. Shell Programming and Scripting
I am trying to use awk to extract and print the first ocurrence of NM_ and NP_ with a : before in each line. The input file is tab-delimeted, but the output does not need to be. The below does execute but prints all the lines in the file not just the patterns. Thank you :).
file tab-delimeted
... (2 Replies)
Discussion started by: cmccabe
2 Replies
3. Shell Programming and Scripting
In the awk, thanks you @RavinderSingh13, for the help in below, hopefully it is close as I am trying to update the value in $12 of the tab-delimeted file2 with the matching value in $1 of the space delimeted file1. I have added comments for each line as well. Thank you :).
awk
awk '$12 ==... (10 Replies)
Discussion started by: cmccabe
10 Replies
4. Shell Programming and Scripting
Hi all,
I'm new to scripting.. facing some problems while inserting content of a file into another file...
I want to insert content of a file (file2) into file1, before first occurrence of "line starts with pattern" in file1
file1
======
working on linux
its unix world
working on... (14 Replies)
Discussion started by: Jagadeesh Kumar
14 Replies
5. Shell Programming and Scripting
S 0.0 0.0 (reg, inst050)
k
e
f
d
c
S 0.0 0.0 (mux, m030)
k
g
r
s
x
v
S 0.0 0.0 (reg, inst020)
q
s
n
m (12 Replies)
Discussion started by: ctphua
12 Replies
6. Shell Programming and Scripting
I want to read from file 1 and pattern match in file two and print field two from the next line.
File 1:
user1
user2
user3
File 2:
name=user1
gud=12345
name=user2
gud=32456
I have this pattern hardcoded but can't work out how to pass file 1 to the pattern match: (6 Replies)
Discussion started by: u20sr
6 Replies
7. Shell Programming and Scripting
Given an XML file that contains (NOT "consists of"):
</dict>
<key>system.</key>
<dict>
<key>rule</key>
<string>default</string>
</dict>
<key>system.burn</key>
... (9 Replies)
Discussion started by: jnojr
9 Replies
8. Shell Programming and Scripting
Hi, I have 2 files that I have modified to basically match each other, however I want to determine what (if any) line in file 1 does not exist in file 2. I need to match column $1 and $2 as a single string in file1 to $1 and $2 in file2 as these two columns create a match.
I'm stuck in an AWK... (9 Replies)
Discussion started by: right_coaster
9 Replies
9. Shell Programming and Scripting
Hi
i have a file which have a pattern like this
Nov 10 session closed
Nov 10 Nov 9 08:14:27 EST5EDT 2010 on tty .
Nov 10 Oct 19 02:14:21 EST5EDT 2010 on pts/tk .
Nov 10 afrtetryytr
Nov 10 session closed
Nov 10 Nov 10 03:21:04 EST5EDT 2010
Dec 8 Nov 10 05:03:02 EST5EDT 2010
... (13 Replies)
Discussion started by: Himanshu_soni
13 Replies
10. Shell Programming and Scripting
Hi,
Below is my input file:
Data: 1
Length: 20
Got result.
Data: 2
Length: 30
No result.
Data: 3
Length: 20 (7 Replies)
Discussion started by: edge_diners
7 Replies