10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
At begining of column 2 the same block (2000) have 3 lines, in the next block (2336) it have 9 lines and for block (2524) 3 lines. ... (0 Replies)
Discussion started by: jiam912
0 Replies
2. Shell Programming and Scripting
The awk below uses the tab-delimeted fileand reformats each line based on one of three conditions (rules). The 3 rules are for deletion (lines in blue), snv (line in red), and insertion (lines in green). I have included all possible combinations of lines from my actual data, which is very large.... (0 Replies)
Discussion started by: cmccabe
0 Replies
3. Shell Programming and Scripting
HI
i have two files say test and test1
Test.txt
Code:
Lun01 2TB 1.99TB 99.6%
Lun02 2TB 1.99TB 99.5%
Lun03 2TB 1.99TB 99.5%
Lun04 2TB 1.55TB 89.6%
Code:
Test1.txt
Lun01 2TB 1.99TB 89.5%
Lun02 2TB 1.99TB 99.5%
Lun03 2TB 1.99TB 99.5%
Requirement is to compare... (6 Replies)
Discussion started by: venkitesh
6 Replies
4. Shell Programming and Scripting
In the following tab-delimited input, I am checking $7 for the keyword intronic. If that keyword is found then $2 is split by the . in each line and if the string after the digits or the +/- is >10, then that line is deleted. This will always be the case for intronic. If $7 is exonic then nothing... (10 Replies)
Discussion started by: cmccabe
10 Replies
5. Shell Programming and Scripting
Hi everybody,
I'm trying to replace the $98 field with "T" if the last field (108th) is T
I've tried
awk 'BEGIN{OFS=FS="|"} {if ($108=="T")sub($98,"T"); print}' test.txt
but that doesn't do anything
also tried
awk 'BEGIN{OFS=FS="|"}{ /*T.$/ sub($98,"T")} { print}' test.txt
but... (2 Replies)
Discussion started by: jghi123
2 Replies
6. Shell Programming and Scripting
Hello,
I have File1 in a directory A, a File2 in a directory B.
If the File2 is not empty
Then I have to move File1 from directory A to a directory archive
Else no action.
Is it possible to do this from one command line?
Thank you in advance for your answers.
Madi (2 Replies)
Discussion started by: AngelMady
2 Replies
7. Shell Programming and Scripting
Sorry Guys for not being able to explain in one of my earlier post.
I am now putting my requirement with the input file and desired output file.
In the below input file -
Transaction code is at position 31:40.
Business code is from position 318:321
TSCM00000005837 ... (7 Replies)
Discussion started by: varunrbs
7 Replies
8. Shell Programming and Scripting
Hi,
I am new to unix shell programming.
I want to write a shell script for a functionality existing in mainframe system.
I have one file as below as input
123456
&__987
&12yuq
abcdef
_ referes to blank
condition:whenever the input file is having &__ ,it should be replaced... (4 Replies)
Discussion started by: charan0703
4 Replies
9. Shell Programming and Scripting
I need only those records which has $2 equal to "DEF" independent of case (i.e upper or lower)
nawk -F"," '$2 ~ //{print $0}' file
This returns 3rd record also which i dont want
I tried this but this doesnt work as expected.
nawk -F"," '$2 == ""{print $0}' file
i dont... (3 Replies)
Discussion started by: pinnacle
3 Replies
10. Shell Programming and Scripting
I have the file with the records like
4234234 US phone
3244234 US cup
2342342 CA phone
8947234 US phone
2389472 CA cup
2348972 US maps
3894234 CA phone
I want the records with (US,phone) as record to be in one file, (Us, cup) in another file and (CA,cup) to be in another
I mean all... (12 Replies)
Discussion started by: superprogrammer
12 Replies