This is a discussion on Calculations across different lines & columns of a file within the Shell scripting forums, part of the Development/Scripting category; Thank you for the wonderful guide LSST (I read it at freeos.com). I am very new to shell scripting but ...
|
|||||||
| Register | FAQ | Members List | Calendar | Forgotten your password? | Mark Forums Read |
|
|||
|
Thank you for the wonderful guide LSST (I read it at freeos.com).
I am very new to shell scripting but learning by experimentation. I have to write a script to do the following: There is a file which has to be manipulated in many ways as given after the data in the file below: Code:
Description Current Val Max Val Err Val firstparam 5403 8000 0 secondparam 350 10000 0 third param 458950 600000 5 param fourth 8190 10000 0 is (third's curr val + second's curr val) > param fourths maxval ??? scan all values in err val column to chk if any value above 0 Any help in this matter would be highly appreciated |
| Sponsored Links | ||
|
|
|
|||
|
Thank you for that code, but after posting here I went back to the tutorials and did some logic building again for the requirement I had in mind. I worked out some other method than what you mentioned (tho the commands are similar to what you've used here). As I mentioned, the requirement is calculations across the rows...what I meant is value of row3, col2 added to row4, col2 added to row5, 2 and then compared to value of row6, col4 and based on that perform some other tasks like mailing the user...ill try to post what i have done already tomorrow as its quite late now and i am sleepy too...thanks indeed for your response.
|
![]() |
| Bookmarks |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) |
|
| Thread Tools | |
| Display Modes | |
|
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to print some lines from a file | Prahlad | Shell scripting | 3 | 04-24-2008 12:25 AM |
| Script to display number of lines and words from a file | newbewie | Shell scripting | 2 | 12-07-2007 11:37 PM |
| Create output in columns | rakeshrhn | Shell scripting | 5 | 12-07-2007 07:27 PM |
| help me in editing this columns | sureshbup | Shell scripting | 1 | 12-12-2006 03:29 PM |
| rearranging columns in a text file | sureshbup | Shell scripting | 2 | 12-06-2006 10:43 AM |