10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
awk/sed newbie here. I have a HTML file and from that file and I would like to retrieve a text word.
<font face=arial size=-1><li><a href=/value_for_clients/Tokyo/abc_process.txt>abc</a> NDK Version: 4.0 </li>
<font face=arial size=-1><li><a... (6 Replies)
Discussion started by: sk2code
6 Replies
2. Shell Programming and Scripting
Hey folks. I wrote a little awk script that summarizes /proc/net/dev info and then pipes it to the nix column command to set up column spacing appropriately.
Here's some example output:
Iface RxMBytes RxPackets RxErrs RxDrop TxMBytes TxPackets TxErrs TxDrop
bond0 9 83830... (3 Replies)
Discussion started by: ryran
3 Replies
3. Shell Programming and Scripting
Hi,
I need an awk script (or whatever shell-construct) that would take data like below and get the max value of 3 column, when grouping by the 1st column.
clientname,day-of-month,max-users
-----------------------------------
client1,20120610,5
client2,20120610,2
client3,20120610,7... (3 Replies)
Discussion started by: ckmehta
3 Replies
4. Shell Programming and Scripting
Hi Friends,
I have a file1 with 3400 records that are tab separated and I have a file2 with 6220 records. I want to merge both these files. I tried using join file1 and file2 after sorting. But, the records should be (3400*6220 = 21148000). Instead, I get only around 11133567. Is there anything... (13 Replies)
Discussion started by: jacobs.smith
13 Replies
5. Shell Programming and Scripting
Hello,
BC106081_abc_128240811_128241377 7.96301
BC106081_abc_128240811_128241377 39.322
BC106081_cde_128240811_128241377 1.98628
BC106081_def_128240811_128241377 -2.44492
BC106081_abc_128240811_128241377 69.5504
FLJ00075_xyz_14406_16765 -0.173417
... (3 Replies)
Discussion started by: Diya123
3 Replies
6. Shell Programming and Scripting
Hi all,
I hope you guys can help me.
I prefer SED/AWK solutions if possible. For my shame it didn't work for me :o
ISSUE: :wall:
1\3
1/$4\@7\
1234567890123456789\
1234567890123456789,\
1234567890123456789\
123456789012
12345
1234567890123456789\
1234567890123456789,\
1234... (5 Replies)
Discussion started by: unknown7
5 Replies
7. Shell Programming and Scripting
Hello all,
this should really be easy for you... I need AWK to print column maxima for each column of such input:
Input:
1 2 3 1
2 1 1 3
2 1 1 2
Output should be:
2 2 3 3
This does the sum, but i need max instead:
{ for(i=1; i<=NF; i++)
sum +=$i }
END {for(i=1; i in sum;... (3 Replies)
Discussion started by: irrevocabile
3 Replies
8. Shell Programming and Scripting
Hi,
I have a script that, basically, has two input files of this type:
file1
key1=value1_1_1
key2=value1_2_1
key4=value1_4_1
...
file2
key2=value2_2_1
key2=value2_2_2
key3=value2_3_1
key4=value2_4_1
...
My files are 10k lines big each (approx).
The keys are strings that don't... (7 Replies)
Discussion started by: fzd
7 Replies
9. Shell Programming and Scripting
Hi,
I have filename in the following format:
YUENLONG_20070818.DMP
HK_20070818_V0.DMP
WANCHAI_20070820.DMP
KWUNTONG_20070820_V0.DMP
How to retrieve only the digital part with sed or awk and return the following format:
20070818
20070818
20070820
20070820
Thanks!
Victor (3 Replies)
Discussion started by: victorcheung
3 Replies
10. UNIX for Dummies Questions & Answers
Hi,
I'm looking for a command to retrieve a block of lines using sed or grep, probably awk if that can do the job.
In below example,
By searching for words "Third line2" i'm expecting to retrieve the full block starting with 'BEGIN' and ending with 'END' of the search.
Example:
... (3 Replies)
Discussion started by: learning_linux
3 Replies