tjd_maximum
April 12th, 2010, 06:32 AM
Hey,
I'm pretty bad with shell scripting. I find it pretty cryptic and have never really found a good guide on it. Anyway, what I'm trying to do is pretty simple I think.
I have a file with some couple hundred lines of data in two columns. Each line looks like:
NUMBER1 NUMBER2
Now, if NUMBER1 is greater then a given value, call it MAXVAL, then NUMBER1 goes to file1, and NUMBER2 goes to file2. Otherwise, I want to ignore the line completely.
Any ideas on a complete or partial solution? I'm sure for someone this is pretty easy. Any help would be appreciated. Thanks.
I'm pretty bad with shell scripting. I find it pretty cryptic and have never really found a good guide on it. Anyway, what I'm trying to do is pretty simple I think.
I have a file with some couple hundred lines of data in two columns. Each line looks like:
NUMBER1 NUMBER2
Now, if NUMBER1 is greater then a given value, call it MAXVAL, then NUMBER1 goes to file1, and NUMBER2 goes to file2. Otherwise, I want to ignore the line completely.
Any ideas on a complete or partial solution? I'm sure for someone this is pretty easy. Any help would be appreciated. Thanks.