10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
hi Gurus,
I have an extract as seen below:
INPUT
2015-08-24 15:00:00.0 |TCSERVER01 |ServiceEventHandler |2283
2015-08-24 15:01:00.0 |TCSERVER01 |ServiceEventHandler |576
2015-08-24 15:02:00.0 |TCSERVER01 |ServiceEventHandler |833
2015-08-24 15:03:00.0 |TCSERVER01 |ServiceEventHandler... (6 Replies)
Discussion started by: reignangel2003
6 Replies
2. Shell Programming and Scripting
Hi there,
I have 2 files in following format
cat file_1
Storage Group Name: aaaa
HBA UID SP Name SPPort
------- ------- ------
0 21
Storage Group Name: bbbb
HBA UID... (2 Replies)
Discussion started by: jpkumar10
2 Replies
3. Shell Programming and Scripting
Hi, Unix Gurus,
I need sum values from a file. file format like:
0004004
0000817
0045000
0045000
0045000
0045000
0045000
0045000
0045000
0045000
0045000
0045000
0004406
the result should be 459227 (817+45000 ... + 4406)
anybody can help me out (7 Replies)
Discussion started by: ken002
7 Replies
4. UNIX for Dummies Questions & Answers
I am trying to get the sum of the first column of a file. When I use the same method for other files it works just fine... for some reason for the file below it gives me an error that I don't understand... I tried looking at different lines of the file and tried different things, but I still... (7 Replies)
Discussion started by: cosmologist
7 Replies
5. Solaris
Hi
I need to incorporate a 'sum' as follows into a script and not sure how. I have a variable per line and I need them to be summed, e.g below
1
23
1,456
1
1
34
46
How do I calculate the sum of all these numbers to ouptut the answer ( 1,562)
Thanks in advance (3 Replies)
Discussion started by: rob171171
3 Replies
6. Shell Programming and Scripting
Hi
i data looks like this:
student 1
Subject1 45 55
Subject2 44 55
Subject3 33 44
//
student 2
Subject1 45 55
Subject2 44 55
Subject3 33 44
i would like to sum $2, $3 (marks) and divide each entry in $2 and $3 with their respective sums and print for each student as $4 and... (2 Replies)
Discussion started by: saint2006
2 Replies
7. Shell Programming and Scripting
cat *.out |grep "<some text>" | awk '{print $6}'
For ex,This will reutrn me
11111
22222
is it possible to add these two numbers in the above given command itself?I can write this to a file and find the sum.
But I prefer to this calculation in the above given line itself.
Any... (3 Replies)
Discussion started by: prasperl
3 Replies
8. Shell Programming and Scripting
Hello everyone I need to write a script that sums numbers passed to it as arguments on the command line and displays the results. I must use a for loop and then rewrite it using a while loop. It would have to output something like 10+20+30=60
this is what I have so far
fafountain@hfc:~$ vi sum... (1 Reply)
Discussion started by: Blinky85
1 Replies
9. Shell Programming and Scripting
Hi
I have an file which looks like
country address phone amount
sweden |address |phone | 10 |
Singapo |address |phone | 20 |
Italy-N |address |phone | 30 |
denmar |address |phone | 40 |
Here i need to do the sum(amount), how to do this in shell scripting
Thanks
Babu (11 Replies)
Discussion started by: ksmbabu
11 Replies
10. Shell Programming and Scripting
Hi,
I have a challenging task,in which i have to find the duplicate files by its name and size,then i need to take anyone of the file.Then i need to open the file and find for more than one pattern and count of that pattern.
Note:These are the samples of two files,but i can have more... (2 Replies)
Discussion started by: jerome Sukumar
2 Replies